Ians Ramblings Ian's ramblings, daily, ish

25Feb/090

NFS mount with differing UID and GID

Geeky post alert! Just thought I would put this snippet of info here incase anyone else has the same problems I did when getting an NFS mount to be writable when you do not have automatically synchonsed user accounts on both the NFS server and the machine you are mounting on.


The following actions should be carried out on the "server" machine, i.e. the machine that actually has the directory(s) that are being shared.

Firstly you need to ensure that NFS as a service is running (execute these as root): -

rpcinfo -p

This should return something like the following if the service is running: -

100003 2 tcp 2049 nfs
100003 3 tcp 2049 nfs
100003 4 tcp 2049 nfs

If the service is not running you should run: -

/etc/init.d/nfs start
Create the user you want the client machine to authenticate as with the useradd command, once the user is added run the following command to get the UID and GID of the user
id boristheuser

Should return something like: -
uid=500(boristheuser) gid=500(boristheuser) groups=500(boristheuser)

You can then add the directory you want to share with read and write access to the given host.
The directory must then be listed in the exports file "/etc/exports" an example is: -
/opt/share Client(rw,sync)
In this example the machine I intend to mount the directory on is known as "Client" in my "/etc/hosts" file.
Once added the following command should be executed or I believe you can restart the whole NFS service and get the same result: -
exportfs -ra
The next set of instructions should be executed on the "client" machine.
Now you can add the NFS mount point to the "/etc/fstab" the entry in the fstab should be something like (all one line): -
Server:/opt/share /opt/nfs_share nfs rw 0 0
In this example the machine I intend to mount the directory from is known as "Server" in my "/etc/hosts" file.

You now need a corresponding user on the "Client" you should add the user using the "useradd" command, if the uid and gid differ on the two machines, you can either automatically keep both in sync with a tool such as RSync, or you can manually change both UID and GID's to an arbritary value, usually over 99.

You can change the UID and GID of a user with the "usermod" -u and "usermod -g" commands

Once the command "mount -a" is executed the directory should now be available and read / writable in /opt/nfs_share/
This can be checked by running "df -h"

If you need to make changes to config and re-mount you will need to run the umount command against your mount point first, for example: -

umount /opt/nfs_share/
mount -a

where the directory being umounted is the one mentioned in your fstab.

I used the following page for troubleshooting this procedure: http://tldp.org/HOWTO/NFS-HOWTO/troubleshooting.html

Filed under: Uncategorized No Comments
24Feb/090

Shiny VMWare Server

Well, after the untimely demise of my little server here, and it's reincarnation as a very frail version of it's former self, I had some excellent news.


The company I work for namely Phil and Steve hehe, managed to get hold of an older unused server for me, that's a beasty, thanks again chaps!

It's a dual Xeon 2.4 with 4 gig of ram with 4 disks run through a 3ware raid controller in a nice mat black 4u case.

The server is now running the newest VMWare Server which only needed a little fiddling to get working, now sees both CPUs. The virtual webserver from which you are reading this page, and other virtual machines all ported over smoothly.

The tweaking needed to get VMWare server working was really just to ensure the kernel-devel package was installed for my kernel, originally I didn't realise when searching for the kernel-devel pack if you have 4 gig of ram or more, you should be using the PAE kernel.

Filed under: Uncategorized No Comments
21Feb/091

Poor Old Webserver

Today on opening the door to my little server room I was greeted by the sound of an alarm coming from the internal speaker of the webserver that runs this site. Bless it, it had been running non-stop for nearly 2 years on an old machine I built back in 2001.


Luckily just to be super cheap, I called a local computer repair chap who had some spare old parts, I bought a bundle of them just to get the old server back up and running again.

The reason the machine had died was a faulty CPU fan, it gave the message "cpu fan not functioning correctly", initially I just tried replacing the whole CPU cooler with a huge beast of a cooler by Arctic, unfortunately same error. After trawling forums and what not I discovered that message will still appear even if the motherboard is more or less a gonner, in my case the resistors had bulged and burst, lovely.

Well at least it is functioning again, all be it on one eigth of the amount of RAM it had before! What I need now is someone to kindly donate an old server hehe..

Filed under: Uncategorized 1 Comment
18Feb/090

Gran Torino Revisited

Well after having seen an advert showing a few more snippets from Gran Torino, I decided to give it another go, not too proud to go back on the 10 minute rule hehe.


After skimming over the first 20 mins or so it becomes very interesting, although uncomfortable tone and pace throughout the slow relationship building between Clint and the neighbours is very interesting.

The cultural differences and the kindness of the neighbours really reminds me of the experiences I have had with my girlfriend Analie and her lovely friends and seems very authentic.

The story is certainly rather a tragedy, interesting, unpleasent to watch I found, but leaving me with some sense that the right thing was done.

gran torino


All in all I am glad I gave it a chance, I found it interesting quite moving and worth watching. It is however not something that's going to brighten up anyone's day!
Filed under: Uncategorized No Comments
14Feb/090

Gran Torino, 4th in the 10 mins to bin collection

Well this is the kind of posting that will annoy some people, but ah well!


I will start by saying I have this annoying habit of being able to watch a few minutes, let's say up to 10 minutes and decide that a film is not for me. Either it's general tone is not my cup of tea, it's opening is so weak and feeble / lifeless / directionless or it's character introductions so un-belivable / un-realistic or cheesily cliche.

Now I personally have found four films lately that nestle nicely into the above 10 minutes and welcome to the dustbin category.

It started with "no country for old men", that fell into un-realistic and cheesey on a numerous accounts including the slow moving weirdo with the air hose thing, having seen the guy I would have strangled him with his airhose and stuck it where the sun don't shine.

The next film to fall foul of my ten minute rule was into the wild, the droning whinnings of an over privileged looser who managed by the power of magic to shoot a moving squirrel from the hip with a rifle, of course both unrealistic and fully un-inspiring it went into the bin.

The next and possibly slightly unfair addition to this posting was eastern promises, its general opening cheapness and cliche underground tarentino smell about it that caused my almost immediate distain and finally led to it's binning after 10 mins. I think I can put 50% of this down to mood the other 50% down to a weak opening.

The final movie, one I watched this evening, Gran Torino, well starts mind numbingly boring, the totally standard issue whining american family, the droning on and tedious focus on vietnam as soon as someone over 50 is in the movie, the tediously predictable grimise and scowling of Clint, shall I say more, this might be one of the first not to have even hit the golden 10 mins.

Well that's my insight into those 4 films that everyone who thinks they know something about films thinks they have something to say about, luckily I was glad to say I saved quite a few hours of live by sin binning them.
Filed under: Uncategorized No Comments
14Feb/090

E71 lives again

well almost... My phone had to be totally replaced, though I am using it right now to create this blog entry whilst on the coach back from coventry hehe not bad.

Filed under: Uncategorized No Comments
7Feb/090

Boo Phone Broken

If anyone wonders why I am not responding on my Phone its because the poor little creature won't start, looks like it's a problem lot's of E71 users are having, Nokia discussion forum


For me attaching my E71 via a datacable when it is in this conditions it is reported as a Nokia USB ROM which immediatly disconnects as soon as it detects it.

Attaching the power for mine had no effect and removing the battery and sim and replacing them also had no effect.

If other people are looking for ways to hard or soft reset their Nokia E71 these are the two techniques:-

Note: Backup everything, if you can before running these.

Soft reset:

Type *#7370# and the use PIN: 12345

Hard reset:

Press and hold Green, * and 3 and keep them held whilst powering on and for a few seconds after

Neither work for me, so the phone is going off for repair boo..
Filed under: Uncategorized No Comments
   
6 visitors online now
6 guests, 0 members
Max visitors today: 6 at 01:12 am UTC
This month: 6 at 08-01-2010 01:12 am UTC
This year: 48 at 06-10-2010 05:19 am UTC
All time: 48 at 06-10-2010 05:19 am UTC