PDA

View Full Version : Changing amanda user using packaged version



tvleavitt
September 24th, 2009, 04:25 PM
I'm running Amanda on Ubuntu Hardy (8.04.3 LTS)

Linux argus.wafergen.com 2.6.24-24-server #1 SMP Fri Jul 24 22:44:54 UTC 2009 x86_64 GNU/Linux

# dpkg -l | grep amanda
ii amanda-client 1:2.5.2p1-1 Advanced Maryland Automatic Network Disk Archiver (Client)
ii amanda-common 1:2.5.2p1-1 Advanced Maryland Automatic Network Disk Archiver (Libs)
ii amanda-server 1:2.5.2p1-1 Advanced Maryland Automatic Network Disk Archiver (Server)

I just purchased a Promise SmartStor NS4300n, and am attaching it to a GigE network. I can't use NFS to mount drives off these things, as they apparently use UDP style NFS which doesn't work on a GigE network, so I'm mounting them as Samba mounts. Which is all fine.

Except that the default "backup" user that amanda runs under on Ubuntu, is UID 34. ... which the SmartStor won't let me write to the device as. Presumably because that's a reserved UID. Instead, everything gets changed to the UID of the user this is being mounted as on the SmartStor (UID 1001).

So I tried changing the ownership of everything on the server to that same UID, to no effect. This is the error I get.

Amanda Backup Client Hosts Check
--------------------------------
ERROR: NAK argus.wafergen.com: user smartstor from argus.wafergen.com is not allowed to execute the service noop: /var/backups/.amandahosts: owned by id 1001, should be 34 Client check: 1 host checked in 0.007 seconds, 1 problem found

(brought to you by Amanda 2.5.2p1)

***

Am I correct in reading the documentation and discussion thread to indicate that Amanda is hardcoded at compile time to run as a particular user (backup, UID=34), and changing this requires re-compilation?

If so, what's the way around this that will let me write my backups to the network device?

choogendyk
November 2nd, 2009, 06:47 PM
Did you resolve this question?

The Amanda user is a configure option (the first step in building Amanda from source). That is necessary because there are many things that have to be installed with the proper ownership to work. See http://wiki.zmanda.com/index.php/Installation/Installing_Amanda_Source, or see http://wiki.zmanda.com/index.php/Quick_start for a broader overview. So, yes, you would have to build it from source if you want the user to be different than what your package distribution is set for.

The errors you are seeing (quoted in your message) are because you tried changing the ownership of things.

What is it that you are trying to do? Is this smartstor supposed to serve as a virtual tape setup for your backups?

When you mention that the smarstor cannot do a samba mount as UID 34, and you say, "Presumably because that's a reserved UID," are you guessing? Or does their documentation actually say that? I find that rather odd. It's not a Samba constraint. I don't think smb is mapping UID's or requiring that they match. It is the user name and password that go across. If you repair the ownership changes you made, perhaps we could explore how to make that work?