Amanda-Users

Re: ERROR: 192.168.0.73: [host u03: port 57341 not secure]

2004-01-08 12:07:52
Subject: Re: ERROR: 192.168.0.73: [host u03: port 57341 not secure]
From: Gene Heskett <gene.heskett AT verizon DOT net>
To: el AT infochem DOT de, adellam AT sevenseas DOT org
Date: Thu, 8 Jan 2004 12:06:33 -0500
On Thursday 08 January 2004 10:00, Eugen Leitl wrote:
>Andrea Dell'Amico wrote:
>> Don't do that, neither. Assign the group "backup" to the amanda
>> user, chown root /usr/local/sbin/amcheck, and then rerun it as
>> amanda.
>
>I've done what Gene Heskett said:
>
># cat /etc/group
>...
>backup::303:amanda
>...
># cat /etc/passwd
>...
>amanda:x:400:303:Amanda Operator:/Disk2/amanda:/bin/bash
>...
>
>As user amanda:
>bash-2.00$ tar zxvf amanda-2.4.4p1.tar.gz
>...
>bash-2.00$ export LDFLAGS="-L/usr/local/lib -R/usr/local/lib"
>bash-2.00$ cd amanda-2.4.4p1
>bash-2.00$ ./configure --with-user=amanda --with-group=backup
>...
>bash-2.00$ make
>...
>bash-2.00$ su
># make install
>...
>bash-2.00$ id amanda
>uid=400(amanda) gid=303(backup)
>
>bash-2.00$ amcheck daily
>bash: /usr/local/sbin/amcheck: Permission denied
>
>I've tried diverse suggestions from other posters (thanks!),
>but so far can't get anything other than a verboten, or the usual
>'port not secure' shinola.
>
>Thanks, I'll keep trying.

I haven't posted this for a couple of weeks, so maybe the list will 
forgive me one more time.  Here is the script I use to build amanda, 
executed as the user amanda (it will warn and exit if root runs it)
after you've made amanda the owner of the tarball and unpacked it as 
the user amanda, copy this into the tarball generated directory, set 
the +x bit and run it.  Here I call it gh.cf, but you can call it 
whatever.
-----------------------
#!/bin/sh
# since I'm always forgetting to su amanda...
if [ `whoami` != 'amanda' ]; then
        echo
        echo "!!!!!!!!!!!! Warning !!!!!!!!!!!!"
        echo "Amanda needs to be configured and built by the user amanda,"
        echo "but must be installed by user root."
        echo
        exit 1
fi
make clean
rm -f config.status config.cache
./configure --with-user=amanda \
        --with-group=disk \
        --with-owner=amanda \
        --with-tape-device=/dev/nst0 \
        --with-changer-device=/dev/sg1 \
        --with-gnu-ld --prefix=/usr/local \
        --with-debugging=/tmp/amanda-dbg/ \
        --with-tape-server=coyote.coyote.den \
        --with-amandahosts \
        --with-configdir=/usr/local/etc/amanda

make
-----------------------
change the with-tape-server= to the FQDN of the host server, and take 
out the changer-device line if you don't have one.  The FQDN must 
exist in your dns records, or in the /etc/hosts file.

Also if amanda isn't a member of the group disk, change that to 
whatever has perms to have the run of the system.  It was disk here 
on this formerly rh8.0 system.

This script has been building amanda for me for well over a year now, 
including the 2.4.4p1-20040107 snapshot from yesterday which ran just 
fine last night.

-- 
Cheers, Gene
AMD K6-III@500mhz 320M
Athlon1600XP@1400mhz  512M
99.22% setiathome rank, not too shabby for a WV hillbilly
Yahoo.com attornies please note, additions to this message
by Gene Heskett are:
Copyright 2003 by Maurice Eugene Heskett, all rights reserved.