Installing Ubuntu Server 7.10 (Gutsy) on the Fileserver
Installing from CD
I downloaded the 7.10 Server CD and burnt it. Booting from it gave me a text based installation. All standard stuff. At the end of the installation I chose LAMP, SSH and Samba servers as additional modules to add on.
Testing the network
I then used ping to test the LAN and make sure that the Server was allocated an IP from the Router’s DHCP. ping 192.168.1.1 showed the Router alive and ping www.google.com showed Internet connection working.
Updating
I then used sudo apt-get update to update the package list and sudo apt-get upgrade to upgrade/update my installation. Only two packages were selected
All is going well so far, the next step is to get Webmin installed.
Webmin
As I was going to be doing a lot of ‘root’ work, I set up a root password using sudo passwd root and then logged in as root. To prepare for installation of Webmin I had to download and install the required support libraries, which I did with:
apt-get install openssl libauthen-pam-erl libio-pty-perl libmd5-perl
Peace of cake. The library libnet-ssleay-perl is no longer available. What to do? I found here that the version should be 1.30-1 – so it should be available. A bit of googling later and I found a download link for this version. So I typed:
wget http://ftp.fi.debian.org/debian/pool/main/libn/libnet-ssleay-perl/libnet-ssleay-perl_1.30-1_i386.deb
to download the packages and dpkg -i libnet-ssleay-perl_1.30-1_i386.deb to install it. Phew! That was close – didn’t think I’d get it going.
Then to get Webmin, I used:
wget http://garr.dl.sourceforge.net/sourceforge/webadmin/webmin_1.350_all.deb
To install Webmin, I used dpkg -i webmin_1.350_all.deb and, as promised, it said:
Webmin install complete. You can now login to https://Server:10000/ as root with your root password, or as any user who can use sudo to run commands as root.
“Server” is the name that I chose to call the server – now nobody said that I was imaginative!
Then, I noticed from the Webmin site that the latest version was 1.370 (d’oh!) so I am going to have to update it once I get in. I should have downloaded webmin_1.370_all.deb instead.
Anyway, trying to access Webmin across the LAN using https://server:10000 failed with a ’server not found’ message. Wonder what the IP of the server is?
Hmmm… A small bit of research later and I am no wiser as to what linux CLI command will tell me! Ho hum. Ah yes – log on to the Router and look in the DHCP client list to see which IP has been allocated to Server. Got it – it’s 192.168.1.8.
Updating Webmin
Typing https://192.168.1.8:10000 into a browser (Firefox) takes me to the login page and I can log straight into Webmin – yay! Now this is already one step further than before with 7.04 Feisty. Webmin opens up with some system details and a menu to the left. Clicking on Webmin in that menu and then Webmin Configuration I can choose Upgrade Webmin (Webmin>Webmin Configuration>Upgrade Webmin). I leave the “Latest version from www.webmin.com” selected and click the Upgrade Webmin button. It downloads and installs successfully. At the bottom of the page Webmin tells me that there are 1 updates for this version and I follow the click here link to download it. It is the acl (Access Control List) module and it donwloads and installs flawlessly. Now that was easy. Just to check, I click on System Information in the main menu and it tells me that I am indeed running 1.370. Success.
Samba file sharing
1. I go to Servers > Samba Windows File Sharing.
2. Then, I click on Create a New File Share and fill in the details as follows: Share name = public, Home Directories Share = unselected, Directory to share = /home/public, Automatically create directory = yes, Create with owner = root, Available = yes, Browseable = yes, Share comment = Fileserver stuff.
3. To make sure everybody has got permissions to this folder/share, I click on Others>File Manager and navigate to /home. Damn, Firefox tells me I have to download a plugin, now I know have Flash installed so I am guessing it is either Shockwave or Java, prob. Java. OK, let’s do it. Yup – it was Java.
4. I click on the Info button and check Read, Write and List boxes are ticked on User, Group and Other columns.
5. Lastly, I’ve got to make sure the configuration file is saying the right things. So I navigate to /etc/samba and click on smb.conf and then Edit. A little Java applet window pops up and I can edit the file here – cool, huh? So, what am I looking for? Looking for ; security = user I can now change it to ; security = share.
6. Now I can scroll down to the end of the file, and change:
[public]
comment = Fileserver stuff
path = /home/public
to be:
[public]
comment = public
path = /home/public
public = yes
writable = yes
create mask = 0777
directory mask = 0777
force user = nobody
force group = nogroup
I then click on the Save & Close button. Phew - nearly there.
Windows Workgroup
Right. To check I am going to be part of the same Workgroup as trhe rest of my LAN, I click on Servers>Samba Windows File Sharing>Windows Networking in the Global Configuration section. Here I can set the Workgroup to MSHOME and click Save. That should be it – now to test the share from Windows…
Nah – it is asking for user name and password to get into the share and it shouldn’t do that. Interestingly, from another Linux box I can write to this directory – no problem. Hmm a small problem to solve. I shall be back.
Solution Found
Another dumb mistake easily solved. In the instructions above, you should notice a line in the smb.conf file that now reads ” ; security = share “. Remove the semi-colon at the front of the line! It all works beautifully now.
Job done.
File Server status good
Samba is cool
yep, all went well and Samba works an absolute treat. Now there are several bits I need to configure, like the absence of http: access from other LAN machines (Apache perhaps?) but I am not going to fiddle with the File Server now that it’s got data on it. I’m going to build Render PC 1 and learn more linux on that one…
Powered by ScribeFire.
Installing Webmin
Installing Webmin
I downloaded the RPM from the Webmin website and right-click on the desktop icon, chose Open with “Install Software”. It all seemed to work but to check I went to YaST>Software Management and searched for Webmin to check that it was installed. Woohoo!
Using “https://192.168.1.3:10000″ to reach the Webmin page produced mixed results. The IP is the IP of the file server and it works on the console attached to the Server but not from across the LAN. Mmmmm…
Pinging the Server produces results, so it is present. Ah, the program needs Apache and the openSUSE install doesn’t install LAMP apps automatically. So… back to Package installation and in they go.
Still didn’t work. Can access Webmin from the local console but not across the LAN. Now I’m really confused..
Drat, looks like I’ll have to go back to an earlier step…
Setting up a Server with Ubuntu
OK, the File Server now has new hardware. Faulty memory has been replaced and it has a 320Gb hard drive – which should be enough for some file storage.
Setting up a Server with Ubuntu
What a brilliant idea! I found the following link and after a little reading it reminded me of work that I had been doing before with Windows networks. We had a separate machine that acted as a Firewall – a Red network card for linking to the outside world and a Green one for the internal LAN. However, as I am behind a router I couldn’t get both cards to function properly
However, one brilliant thing I learned was the ability to adminsiter the server remotely by using Webmin – web administration tool.
So that was that idea….
openSUSE 10.3 is out
It has installed brilliantly on Laptop 1 – I haven’t had the balls to try Laptop 2 yet. It has also installed on the new File Server, now to download and install Webmin to see if I can use the Samba section to get working shares.
Now how to set the Samba password?
I’m, guessing this is probably the reason why my Share is not allowing logons. It’s no doubt possible in the way that I did it for Ubuntu but I would like to find out if there is a quicker and more reliable (considering my console knowledge) of doing it. Time to RTFM. The online documentation for configuring Samba, I found here.
Hiding those Shares
The first thing I discovered is that if you go to the Samba Server section of YaST and disable all of those pesky system shares, they no longer pop up in Network Places. Cool, huh? I hope this doesn’t disable functionality, but I guess I’ll find out later.
RTFM
I found the Samba configuration stuff here. The bit that has worked is:
30.4.2 Web Administration with SWAT
An alternative tool for Samba server administration is SWAT (Samba Web
Administration Tool).
It provides a simple Web interface with which to configure the
Samba server. To use SWAT,
open http://localhost:901 in a Web browser and log in as
user root.
If you do not have a special Samba root account, use the system
root account.NOTE: Activating SWAT
After Samba server installation, SWAT is not
activated. To activate it, open
Network Services>Network Services
(xinetd) in YaST, enable the network services configuration,
select swat from the table, and click Toggle Status (On
or Off).
Once this has opened in a browser, click on the PASSWORD button and enter a Samba username & Password. Then click on Add New User. This is the username and password that Windows uses to access the share. Clicking on the Shares button, followed by the Advanced button shows you the permissions of the selected share. This confirmed that R/W permisssons were enabled.
Final confirmation was reading a file from the File Server to Windows and performing the reverse operation. Success at last!
Yay!
Powered by ScribeFire.
Next stages in Samba Configuration
Network Places reports success
Looks good so far, the File Server has appeared in Workgroup Computers and when opened shows half a dozen shares! I don’t want that many available. Groups is requesting a user logon, and Homes has frozen my Explorer – grrrr. I’ve been here before with Ubuntu and this is a real beaut of a crash. Even giving it the old three fingers and task manager can’t get out of it and neither can Shutdown in order to restart the offending Windows PC. The only solution is the BRB - the Big Red Button!!! I’ll be back later, coz I know this machine is going to die for a while due to this. I remember why I wanted Linux.
Powered by ScribeFire.
openSuse installs well, but what about Samba?
Laptops finally installed
Each of the two laptops have openSuse 10.2 installed on them. Amazingly, after they both rejected the other distros (and the HP pavilion rejected XP), they are both running openSuse well. OK, the slower laptop is a bit kludgy, but less kludgy than it used to be with Windows installed (which for some reason won’t go back on!).
Laptop 1 (the Toshiba Tecra) was an interesting install. The setup window was only two-thirds visible on the screen. In order to get to the Accept/Cancel buttons at the bottom of the screen, and therefore invisible, I had to press TAB and then Return – hoping that I had hit the right button. After several amusing, finally frustrating, attempts it installed very well. The graphical stage setup at the end of installation allowed me to set the screen resolution and even the screen ratio perfectly. I am very impressed with the result.
File Server Resurrected
After removing the 120 Gb drive, the old FS only had 80Gb left, but Suse 10.2 installed on it with no problems at all. I do notice that Suse uses a Reiser file system for formatting its partitions rather than ext2 or ext3 that Ubuntu used. This is still rather a mystery to me – what are the differences/advantages? Dunno yet.
How do I configure Samba in openSuse?
Ah yes, the system I learned from the Micro Mart magazine for Ubuntu did not, of course, work. So, I started browsing through the ‘Computer’ menu. This is the sequence that I have tried so far.
- Select Computer>More Applications…
- A window pops up with sections corresponding to the old familiar menus. I went to the System section and selected YaST (Administrator Settings).
- Enter the root password for Administrator privileges.
- Click on Network Services, which shows you two entries on the right hand side that have got to be important. Samba Server and Windows Domain Membership. Sounds easy so far.
- Click on Samba Server. It starts up, showing the Shares Tab.
- Reading the help bit on the left sidebar, I click on the Filter button and ‘Do not show System Shares’.
- That leaves me with two entries: /home/groups and /home. Mmmmm..
- I flick back to the File Browser and create a Folder in my home directory called ’smbshare’ that I intend to share and return to the YaST program.
- OK, so next I go for the ‘Add…’ share button.
- It wants a Share Name – I call it Share, a description – ‘Windows files’, leave the Directory radio button ticked and Browse for the Path.
- Leaving the other options unchanged, I clilck OK and return to the Shares Tab (Damn, I’ve got to select the filter again to clear the list), and there is my Share. I also put an X in the box to allow users to share their directories with other users. I’m hoping that enables the Linux machines to talk to each other.
- Click on the Start-up Tab and select start the service during Boot and Open Port in Firewall.
- On the Identity Tab, I set Workgroup as ‘MSHOME’ – the name of the Windows Workgroup the rest of my LAN is used to operating in. I also leave the Domain Controller section set to ‘Not a PDC’ as we’re just using workgroups and no domain serving.
- I’m not sure about the NetBIOS settings or any of the Advanced settings so I leave them alone. Phew!
Windows Domain Membership
- Domain or Workgroup is set at MSHOME. Wel, that’s got to be good.
- I then click Browse, expecting to see my workgroup listed, and disappointment strikes – nothing!
- On closing, it informs me that Samba-Winbind has to be installed, so I agree.
Well, that flummoxed me. Obviously, something is not working. In true Windows style, let’s try a Restart.
A quick note
Something to try. I found this on another blog and it looks like it is definitely worth a try when trying to work the other way round, i.e. mapping network drives on the linux machine. The Places>Network menu opens up a browser like Network Neighbourhood but mapping a share permanently sounds really cool. I’m definitely off for that coffee, but here is the link…
Good stuff.
Let’s try the Ubuntu Desktop
Ubuntu Desktop 7.04
So the next step is to try the other installation disk for Ubuntu.
One download later, I have another iso to cut to disk. Not knowing how to reformat the disks for a clean install under Linux, I re-install Windows XP and boot into the installation CD. I do like the pretty loading screen. Silly I know but the black screen with the Ubuntu logo and the sliding progress bar makes me feel somewhat at home. I’m used to this sort of presentation with Windows and it gives me a degree of confidence that this installation knows what it is doing.
As with the server, the next most complicated decision I have to make during the installation process is how to format the Hard Drives. I don’t understand all of the options it gives me and I know I don’t want Windows to retain a partition on the machine so I opt for the Guided Entire Disc option. It takes about 25 minutes to install all of its packages and ask me to remove the CD prior to re-booting. All seems good so far.
Oh yes! It boots into a clean graphical screen with a login prompt. I enter the username and password that I have chosen and am presented with a very clear and clean desktop. This looks very good. A calm relaxing beige desktop with a taskbar, which I later discover is called a panel, at the bottom of the screen and another at the top. All of the hardware seems to have been detected, even the sound card. A quick browse amongst the buttons and options and I feel as though a have a full function PC at my control again. I’m very impressed.
Back to the article in Micro Mart and it talks about configuring something called Samba. You need Samba so that the Linux operating system knows how to access Windows shares and that is going to be essential if I want to use this machine as a File Server.
Samba Configuration
The instructions here are pretty simple.
1. Go to System>Administration>Network and re-enter the password. I have a wired network so I leave the first tab alone and go to the next one ‘General’. Here I can enter a hostname for the system and I choose ‘Server’ which seems to describe the machine pretty well. I notice that it has successfullyassigned an IP to the machine using DHCP supplied by my router, so all still looks good. Click Close and come out of this program.
2. Go to System>Administration>Shared Folders. At this point a little message has flashed up n the top Panel telling me system updates are needed. Now that’s more like it – the system has recognised that more software is needed and will install it for me, and in a Windows Update fashion, will keep my system up to date. Feeling better and better all the time. This all works beautifully and I can continue by going to the ‘General Properties’ tab on the Shared Folders program. This Administration menu seems more and more like Control Panel – so I’ve got some idea of what I’m doing – not much though
3. Here I can enter the Workgroup name I use for my Windows machines (MSHOME – not very original) and click on close.
4. Now it gets a bit scary – I have to edit the Samba configuration file! So, I go to Applications>Accessories>Terminal and up pops a Notepad like text editor. All it says is ‘gary@server:-$’ – mmmm….. Well, gary is my username, Server is the hostname so I guess I can understand this prompt and it looks like an MS-DOS command line. I then have to type ’sudo gedit /rtc/samba/smb.conf’ here. It has asked me for a password again – the magazine didn’t say anything asbout this. OK, I’ll use the only one I know which is the one set up during the install process as the magazine says that sudo means the command is run as an administrator and not as a user. The ‘gedit’ bit is the actual Notepad like editor it is going to start and all the rest is the path and document I am going to be editing.
5. It works! I get a full screen text editor which has a huge configuration file loaded. I have to search through the file to find the ‘Home Directories’ bit and change the value browseable to yes (it was no original). I also have to un-comment the line. I also have to change ‘writeable’, a few lines down, to yes. So far so good. I can close the editor, saving the file.
6. Back at the Terminal screen, I have to set a Samba password which I can do by typing ’sudo smbpasswd -a <username>’ where <username> is my username, i.e. ‘gary’. This is so that other machines on the network get a password to access the shared folders. Why do I have to do this? I’m on a secure home network – puzzlement. Still… it’s done.
7. OK, So I close the Terminal window now and go to Places>Home Folder. I right click amongst the folders displayed and create a new fold called ‘Share’. Right click again, and choose ‘Share Folder’. I select ‘Windows Network(SMB) and give it a share name of ‘Share’ – I understand this bit – it’s the same as the Windows way of doing things. A share can have a different name to the actual folder that is shared. I un-check ‘Read only’ as I want to be able to store stuff here and go to my Windows machine to test out the share. Apparently it should all work now.
8. Well, a new network place has popped up called ‘ share on Server server (Samba, Ubuntu) (Server)’. Looks good although how many times do I need to read the word ’server’? I double-click on this and a Connect to Server password dialog box comes up. The username is set to SERVER/gary which all looks good and I have to type in my assigned Samba password. Ok, let’s do it. I also put a check in the ‘Remember my password’ box, that should stop me having to re-enter the password everytime!
9. Success!!!!! It works. I can create folders here and dump stuff over onto the file server to be retrieved at a later date. Definitely time for a coffee to celebrate.