Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

i have a belkin dd-wrt router. It connects to dyndns. I am able to access my Windows XP PC throught the internet, and i have already enabled RDP by forwarding port 3389 to my local IP-address. It works.

How do i enable access to my hard drive or any shared directory? I would like to access the share like this:


Is this even possible?

share|improve this question
up vote 2 down vote accepted

As others have stated, your router would have to be configured to forward the appropriate ports to the computer with the shares. You will be opening up a huge security hole, so consider other options.

Almost anything will be better than SMB/CIFS over the open internet. Personally I'd use SCP/SFTP to take advantage of SSH security. You could even tunnel SMB/CIFS over SSH... in theory. The only thing you'd need to do is 1) setup an SSH server on your computer, and 2) forward SSH ports from your router to the computer.

Now, to your question.

Your URI smb:// won't work because you have two hostnames in there, and HostnameOfMyPC. In theory (and depending on where you were trying to use this), the format would be:

         ^               ^
         |               |
 OR      + host/ip       + share
         |               |
         V               V

You can use any of these for the host/ip field:

  • your alias (resolves to your public IP),
  • your public IP,
  • your HostnameOfMyPC, if and only if you've added it to your hosts file with your public IP (this would go in /etc/hosts on a Unix system, or C:\windows\system32\drivers\etc\hosts on Windows):

    x.x.x.x    HostnameOfMyPC
share|improve this answer

You could try Hamachi: No port forwarding or dyndns needed!

share|improve this answer
+1 And completely secure, too. – harrymc Oct 25 '09 at 13:45
well - as good as this looks, security is debatable when anyone at another company can connect in at will and do what they want! – William Hilsum Oct 26 '09 at 1:43

This is possible, but I would not recommend it at all as it can leave your machine open to attack.

I would personally look in to using something like either an FTP Server such as Filezilla or a HTTP Server such as IIS or Apache.

This will allow you to share the root of your hard drive or any folder and have authentication - along with being a lot safer.

share|improve this answer
Could you tell me how to do it with smb. I need to access XP and Vista – mrt181 Oct 25 '09 at 13:00
You simply enable file sharing then forward all the required ports for SMB - however I REALLY would not recommend this - all the last few big viruses / exploits scan for open SMB shares on the internet and propagate this way. – William Hilsum Oct 25 '09 at 13:08
You can easily install Filezilla Server on Windows, then you can access it using any computer, either using the builtin ftp command, or using Filezilla client. – Rich Bradshaw Oct 25 '09 at 13:10
ok, but which command do i have to use (smb://???????) – mrt181 Oct 25 '09 at 13:14
Most ISP's block the SMB ports anyway so even if you open port SMB over the Internet it probably still won't work. Some ISP block FTP and HTTP as well so you may have to run on a non default port. If possible I would use SFTP (OpenSSH server) since it's secure and ISP are less likely to block it. – shf301 Oct 25 '09 at 17:56

You need to forward port 445 to that machine. Seriously though, as others have said, don't do it. You're asking for trouble with viruses/exploits, etc.

share|improve this answer

Another option, since you are running dd-wrt is to use OpenVPN (you'll need the vpn build of dd-wrt). This allows you to setup a VPN between your remote machine and your local network (i.e. your remote machine will behave as if it's on your home network). This will allow you to access all of the resources on your home network remotely and securely.

Once you have OpenVPN configured on your router you'll need to install and configure clients on any remote machine you want to use.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.