I just recently installed BackupPC and noticed that I could not get the start-stop-daemon to run the program as --user backuppc. I can run the program fine if I log in as backuppc and run the BackupPC executable so it should not be an issue with the program. [root@gentoo sczjd]# eval start-stop-daemon --start --user backuppc --pidfile /mnt/backup/log/BackupPC.pid --exec /usr/local/backuppc/bin/BackupPC -- -d Wrong user: my userid is 0, instead of 51 (backuppc) BackupPC::Lib->new failed Reproducible: Always Steps to Reproduce: 1. If you have BackupPC installed run: eval start-stop-daemon --start --user backuppc --pidfile /mnt/backup/log/BackupPC.pid --exec /usr/local/backuppc/bin/BackupPC -- -d Actual Results: Wrong user: my userid is 0, instead of 51 (backuppc) BackupPC::Lib->new failed Expected Results: started "/usr/local/backuppc/bin/BackupPC -d" as user backuppc Portage 2.0.49-r13 (default-x86-1.4, gcc-3.2.3, glibc-2.3.2-r1, 2.4.20-xfs-r3) ================================================================= System uname: 2.4.20-xfs-r3 i686 Pentium III (Coppermine) Gentoo Base System version 1.4.3.10p1 ccache version 2.2 [enabled] ACCEPT_KEYWORDS="x86" AUTOCLEAN="yes" CFLAGS="-march=pentium3 -O3 -pipe" CHOST="i686-pc-linux-gnu" COMPILER="gcc3" CONFIG_PROTECT="/etc /var/qmail/control /usr/share/config /usr/kde/2/share/config /usr/kde/3/share/config /var/bind /usr/X11R6/lib/X11/xkb /usr/kde/3.1/share/config" CONFIG_PROTECT_MASK="/etc/gconf /etc/env.d" CXXFLAGS="-march=pentium3 -O3 -pipe" DISTDIR="/usr/portage/distfiles" FEATURES="sandbox ccache autoaddcvs" GENTOO_MIRRORS="ftp://ftp.gtlib.cc.gatech.edu/pub/gentoo" MAKEOPTS="-j2" PKGDIR="/usr/portage/packages" PORTAGE_TMPDIR="/var/tmp" PORTDIR="/usr/portage" PORTDIR_OVERLAY="" SYNC="rsync://rsync.namerica.gentoo.org/gentoo-portage" USE="x86 oss avi crypt cups encode foomaticdb gif jpeg libg++ mad mikmod mpeg ncurses nls pdflib png quicktime spell truetype xml2 xmms xv zlib gtkhtml alsa gdbm slang readline arts aalib nas bonobo svga ggi tcltk guile X sdl gpm tcpd pam libwww ssl perl python esd imlib oggvorbis gnome gtk qt kde motif mozilla gphoto2 ldap scanner acl bindist curl evo faad fastcgi ffmpeg flash freetds gd gstreamer gtk2 hbci imagemagick imap imlib2 ipv6 java javascript lcms libgda maildir mbox mcal md5sum mdb memlimit mmx mozsvg mpi nptl odbc ofx parse-clocks passfile php pic ppds samba sasl slp snmp sse threads tiff type1 unicode usb wmf xfs xml xvid -apm -opengl -berkdb"
you could use -c|--chuid <name|uid[:group|gid] instead. it will change to the specified user/group _before_ starting the process.
this worked, thanks why did --user not work?
To quote the manpage: -u|--user username|uid Check for processes owned by the user specified by username or uid.