T

Command Line එකෙන් Network Path එකක් Access කරන ආකාරය

35 views · updated 2026-07-01 · published 2026-07-01 · by Hasarinda Manjula · Microsoft Windows Reading time: 2 min English සිංහල

Overview

Network shares සාමාන්‍යයෙන් open කරන්නේ File Explorer හරහා, නමුත් scripts, remote sessions, සහ quick file transfers වලට command line එක වේගවත්. UNC paths, mapped drives, සහ core commands කීපයක් use කරලා, ඕනෑම accessible share එකක files කෙලින්ම Command Prompt හෝ PowerShell එකෙන් browse කරන්නත් copy කරන්නත් පුළුවන්. මේ guide එකෙන් essential techniques ගැන කතා කරනවා.

Key Takeaways

  • UNC path එකක් \\ServerName\ShareName form එක ගන්නවා.
  • Temporary drive letter එකක් එක්ක UNC path එකකට jump වෙන්න pushd use කරන්න.
  • net use එකෙන් share එකක් persistent drive letter එකකට map කරනවා.
  • PowerShell වලට shares කෙලින්ම access කරන්නත් New-PSDrive එකෙන් mount කරන්නත් පුළුවන්.

Open a Share with pushd

1. Windows + R press කරලා, cmd type කරලා, Enter press කරලා Command Prompt open කරන්න.

2. pushd \\ServerName\ShareName type කරලා Enter press කරන්න.

3. Windows එකෙන් temporary drive letter එකක් assign කරලා ඔබව share එකට ගෙනියනවා, ඒ නිසා dir, copy, සහ වෙනත් commands run කරන්න පුළුවන්.

4. ඉවර වුනාම, popd type කරලා temporary drive letter එක release කරන්න.

Command Prompt එකෙන් UNC path එකකට access කිරීම.

Map a Drive with net use

1. Command Prompt එකේ, net use Z: \\ServerName\ShareName type කරලා Enter press කරන්න.

2. Protected share එකකට credentials දෙන්න /user:DOMAIN\username එකතු කරන්න.

3. Reboot එකකට පස්සෙත් mapping එක තියාගන්න /persistent:yes එකතු කරන්න.

4. Share එක drive Z: විදිහට access කරන්න, පස්සේ එය remove කරන්න net use Z: /delete run කරන්න.

Note: Command Prompt එකට UNC path එකකට කෙලින්ම cd කරන්න බෑ. ඒ වෙනුවට pushd use කරන්න, නැත්නම් net use එකෙන් drive letter එකක් map කරන්න.

Access Shares in PowerShell

1. Start menu එකෙන් PowerShell open කරන්න.

2. Share එකක contents list කරන්න Get-ChildItem \\ServerName\ShareName.

3. Files copy කරන්න Copy-Item \\ServerName\ShareName\file.txt C:\Local.

4. Persistent drive එකක් mount කරන්න New-PSDrive -Name X -PSProvider FileSystem -Root \\ServerName\ShareName -Persist.

Tip: වෙනත් network එකක share එකකට, commands run කරන්න කලින් server name එක resolve වෙන්න මුලින්ම VPN එක connect කරන්න.

Troubleshooting

Problem: The system cannot find the network path.

Solution: Server name එකයි share spelling එකයි verify කරන්න, host එක online කියලා confirm කරන්න, සහ connectivity check කරන්න server එකට ping කරන්න.

Problem: Access is denied.

Solution: net use ... /user: එකෙන් valid credentials දෙන්න, සහ ඔබේ account එකට share එකේ permission තියෙනවද confirm කරන්න.

Problem: Reboot එකට පස්සේ mapped drive එක නැති වෙනවා.

Solution: net use ... /persistent:yes හෝ New-PSDrive -Persist එකෙන් ආයෙත් create කරන්න, එතකොට restarts වලින් survive වෙනවා.

Problem: එකම server එකට multiple connections error එකක්.

Solution: Existing sessions clear කරන්න net use * /delete run කරලා, single credential set එකක් එක්ක share එක ආයෙත් map කරන්න.

Conclusion

pushd, net use, සහ PowerShell equivalents දැනගත්තම, network shares command line එකෙන් ඕනෑම local folder එකක් වගේම reachable. මේ commands තමයි file-transfer scripts සහ remote administration වල පදනම, graphical interface එකක් නැතුව වැඩ කරද්දී වෙලාව save කරනවා.

About TechHub

මේ guide එක TechHub Knowledge Base එකේ කොටසක්. තව step-by-step IT guides සහ support වලට techhub.com.lk එකට යන්න.

Thanks for your feedback! 🙌

Read more

TechHub Assistant
Online · AI assistant
Thinking
⬇ Downloads 📦 Orders 🛒 Buy License 🎫 Create Ticket 🙋 Contact
AI-generated · may be inaccurate. Talk to a human