Wikia

coLinux

Samba

238pages on
this wiki
Talk0

Windows, CoLinux and Samba Edit

Recently I started using CoLinux instead of Cygwin for a lot of my work. CoLinux ensures that I have access to all Linux related software that I use. A lot of Linux software can be accessed via Cygwin, but there are certain times when some obscure or 'non-mainstream' program hasn't been ported to Cygwin and at that point I've been out of luck. Enter CoLinux.

I started to do a lot of software development on CoLinux with lighttpd, Python & WSGI, php, PostgreSQL, etc. After setting up TAP with a static IP, I was able to access my webserver, ssh into the CoLinux box and basically get everything working. BUT, I didn't like the fact that I had to always SSH into CoLinux just to edit a file on the web server for testing, etc. While my command line Vim editing sessions were palatable, I prefer working in GVim for a variety of reasons. So I decided to set up Samba so that I could access everything from Windows that I needed to as if it were a local file. Here are some caveats I found while trying to get it working.

Setting up Samba Edit

To get Samba set up, I'm going to point you to [1]. It is an excellent resource for setting up Samba for CoLinux or just for a regular linux box. Follow the directions therein, noting the following:

  • If you set up the username / pw combo the same as your Windows box, I don't think you'll have to log in. Or you can choose whatever username/pw you want and Windows will prompt you for this name.
  • Make sure whatever you're sharing is readable / writable by any user.

Hopefully that guide will be enough to get you up and running with Samba.

Configuring CoLinux Edit

As mentioned, one of the problems I had was that even after setting up Samba as described above, I still couldn't log in. To fix it, I followed part of what I saw [2]. Specifically, I edited my /etc/network/interfaces file and added the following to the end of my file (i.e., don't remove / edit anything, just add this to the end):


auto eth1
iface eth1 inet static
address 192.168.37.20
network 192.168.37.0
netmask 255.255.255.0
broadcast 192.168.37.255

Make sure that whatever address you use in line 3 above (192.168.37.20 right now) is different from whatever static IP you've configured for TAP. After you finish editing this file, run:

ifup eth1

You should now be able to log into CoLinux via the IP given above if you wanted to. You should also be able to access \\YOUR_HOSTNAME\MyFiles (or whatever you configured Samba with) or \\192.168.37.20\MyFiles (etc.) hopefully with no problems. You can map it in windows and save the username/pw combo and have it automatically connect (open up a windows explorer window, go to Tools | Map Network Drive and go from there).

Hope this helps!

Around Wikia's network

Random Wiki