Daily Do’s – Networking Windows 7 and Ubuntu for File Sharing

I’m back! Did you miss me? Of course you did… but anyways, it’s great to be back.

So I set out on an escapade today. I’ve acquired some new toys recently, and as such have had to reconfigure my network a bit. It was definitely interesting when I decided to network a laptop running Ubuntu 10.04 with a desktop running Windows 7 Ultimate. I have made it work, however, and now I’m going to show you how. If you don’t want a long story, the list of steps is at the bottom.

First off, the equipment in question:

HP G60 Laptop (2008, Wal-mart Edition) running Ubuntu 10.04 (Lucid Lynx)

Acer Aspire AX3200-U3600A Desktop running Windows 7 Ultimate

Girlfriend’s laptop with Win7 Ultimate (Not important to the equation, but this machine will come up in the story below)

Linksys Wireless-G Router (Cheapest G router in Wal-mart. I don’t think your router will matter but you never know).

And on with the show…

Ok, so the endeavor started simply enough: Once I cleared all of Windows 7’s Homegroups off my network (an interesting task to say the least), I set up a new Homegroup so that any computers regularly attached to my network could share files.

But that posed a new question: How do I get my laptop, freshly wiped with Linux installed, to appear within the network on my Windows machine? If you were to do some Googling, you’ll read a lot about a package for Ubuntu called Samba. (Foreshadowing: This eventually solved the problem) From what I read, however, it seemed that was only for the Linux machine to recognize Windows File Shares, which my laptop was already doing no problem. I could access files on my desktop from my laptop no problem, I was just trying to do the reverse!

Well, I created a folder that I intended to drop files I wanted to share into, and attempted to set file sharing to “On” for that folder. Lo’ and behold, it told me I needed to install Samba! Ok, so I did that, giving superuser permissions and all that. Voila! There was my laptop, not inside my Homegroup but definitely inside the Network.


Oh, but if it were just that simple. When I tried to access the shared folders on my laptop, it asked for a Username and Password! I had even enabled Guest access for the folder, which was supposed to allow people without usernames on the machine to access the shared files. Still, Windows just wouldn’t go for it without a username and password.

Coincidentally, I had just messed with User permissions earlier, and something drew me back into the System -> Administration -> Users and Groups menu. I considered many options, such as changing the administration permissions I had just given myself, thinking maybe Linux wouldn’t allow a remote computer to login with an admin account. Then I remembered something: the Domain that Windows had tagged on when I tried to log in (which was the network name of my PC; I’ll call it NERD-PC for now).

Back inside the Users and Groups window, I proceeded to add a new user. When prompted for a username, I gave it the name “NERD-PC/admin” (where admin matches my actual username on the laptop) and just named it “remote” for the short name. I even applied the same password as my original account. The user was created, and made just a “Desktop User” which simply means it can’t (un)install programs or change any system settings. I didn’t care about that, I just wanted my files!

So, after taking a breath, I attempted to log in from the Windows machine again. I just used my normal username “admin” and my password as if I were logging  into the laptop itself. And…


Bam! There were my files. All my pictures, music, etc. that I had backed up before the wipe. I could easily transfer/copy them to my Windows machine! w00t! After that, it was just a matter of making a shortcut to the laptop, as you still can’t get a linux machine into a Windows 7 Homegroup. Still, WAY easier than constantly swapping around a USB Drive.


So for those who don’t like reading, a simple list of steps:

Make sure your Windows 7 Homegroup is setup and properly configured.

Make sure your Linux machine can see the Windows machines on the network. ( Places -> Network -> Windows Network -> WORKGROUP {or the name of your Homegroup if different} ) Note: if you just try to click on the PC’s name before going into Windows Network, it will ask for a username and password. Going into Windows Network first apparently bypasses this. See the PS at the bottom for tips on how to make a shortcut to this location!

Once that’s done, create (or determine) the folder(s) you want your Ubuntu machine to share on the network. Right click them, then click Sharing Options. If you check the box next to Share this Folder, Ubuntu will prompt you to install Samba if you don’t already have it, which you should do. After that, enter a share name for the folder. Guest access is NOT required.

Now, if you open Explorer on the Windows machine, and click Network in the navigation bar on the left, the name of your Linux machine should appear. Double click, and it should ask for a username and password. Make note of the Domain under where it asks for the password.

Back on the Linux machine, go to System -> Administration -> Users and Groups, and click Add.

When the Create New User dialog comes up, in the Name field, enter DOMAIN/accountname. In Short Name, name it something like remote or network. When asked for a password, you may either set one, or Ubuntu can randomly generate one for you. Just make sure you remember what you use! Leave the box next to “Don’t ask for password on login” unchecked.

Once the account is created, close the Users Settings window, then jump back on your Windows machine. Go back into your network, and try to get back into the Linux machine’s shared folders. This time, use your new account you just made on the Linux machine, except remove the DOMAIN/ from the username. You may choose to remember the credentials if you wish.

If everything went right, you should now be able to pull any shared files from your Linux machine onto your Windows 7 PC.


So, that’s it. It sounds way more complicated than it is, I promise. Sound off in the comments or on Facebook if you have any questions, praise, or flames!

P.S. To make a shortcut to a folder in Ubuntu, right click your desktop and click Create Launcher. For Type, set it to Location. Name it, then plug in the path to the folder you want in the Location field (if you use Browse, it’ll want you to actually point it at a file. If it does, just erase the file name and extension from the Location field). Comment if you wish, then click OK. Done!

P.P.S. I’ve recently gotten myself a Droid 2. Nifty! But I’m looking for app recommendations. I’ve posted a status on Facebook for app suggestions. My favorites may get featured in a future blog post!


~ by chadanthony07 on September 6, 2010.

2 Responses to “Daily Do’s – Networking Windows 7 and Ubuntu for File Sharing”

  1. Legend! I’ve been trying to get this working for a good few hours this evening and couldn’t find anything on Google. Then I stumbled across this and had it sorted within 5 minutes. Good work!

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: