Ubuntu: mldonkey-server Installation bricht ab

Folgendes steht in den beiden Dateien:

Code:
#!/bin/sh -e 

CONFFILE=/etc/default/mldonkey-server

case "$1" in
  install|upgrade)
    if dpkg --compare-versions "$2" lt "2.5.1-5" && [ -e /etc/mldonkey.conf ]; then
      echo "Moving /etc/mldonkey.conf to /etc/default/mldonkey-server"
      mv -f /etc/mldonkey.conf $CONFFILE
    fi
  ;;
esac


Code:
#!/bin/sh -e

# Source debconf library
. /usr/share/debconf/confmodule

DEBUG=false

db_get mldonkey-server/launch_at_startup 
launch_at_startup="$RET"

case "$1" in
  configure)

    CONF=/etc/default/mldonkey-server

    if [ "$launch_at_startup" = "true" ]; then

      ###########################
      # Handling debconf values #
      ###########################
      
      db_get mldonkey-server/mldonkey_umask
      mldonkey_umask="$RET"
      umask $mldonkey_umask

      db_get mldonkey-server/run_as_user 
      run_as_user=$RET

      db_get mldonkey-server/mldonkey_group 
      mldonkey_group=$RET
      
      db_get mldonkey-server/mldonkey_dir
      new_mldonkey_dir="$RET"

      db_get mldonkey-server/mldonkey_niceness
      mldonkey_niceness="$RET"
      
      db_get mldonkey-server/client_name
      client_name="$RET"

      db_get mldonkey-server/plugin

      enable_directconnect=false
      enable_opennap=false
      enable_overnet=false
      enable_soulseek=false
      enable_bittorrent=false
      enable_gnutella=false
      enable_fasttrack=false
      OLD_IFS=$IFS
      IFS=", "
      for i in $RET; do 

	case $i in
	Directconnect*)
	  enable_directconnect=true
	  ;;
	Opennap*)
	  enable_opennap=true
	  ;;
	Overnet*)
	  enable_overnet=true
	  ;;
	Soulseek*)
	  enable_soulseek=true
	  ;;
	Bittorrent*)
	  enable_bittorrent=true
	  ;;
	Gnutella*)
	  enable_gnutella=true
	  ;;
	Fasttrack*)
	  enable_fasttrack=true
	  ;;
	esac
      done
      IFS=$OLD_IFS

      db_get mldonkey-server/max_hard_upload_rate
      max_hard_upload_rate="$RET"

      db_get mldonkey-server/max_hard_download_rate
      max_hard_download_rate="$RET"

      db_get mldonkey-server/password
      password="$RET"

      db_get mldonkey-server/max_alive
      max_alive="$RET"


      ###################
      # User management #
      ###################
      
      # Creating MLDonkey group if he isn't already there
      if ! getent group $mldonkey_group > /dev/null ; then
        $DEBUG && echo -n "Creating mldonkey group: "
	addgroup --quiet $mldonkey_group
        $DEBUG && echo "done."
      fi

      # Creating MLDonkey user if he isn't already there
      if ! getent passwd $run_as_user > /dev/null ; then
        $DEBUG && echo -n "Creating mldonkey user: "
	adduser --quiet --system --ingroup $mldonkey_group \
	 --home "$new_mldonkey_dir" --no-create-home $run_as_user
        $DEBUG && echo "done."
      fi

      run_as_useruid=`/usr/bin/id -u $run_as_user`

      if [ ! -d $new_mldonkey_dir ]; then
	$DEBUG && echo -n "Creating mldonkey home directory: "
	mkdir "$new_mldonkey_dir"
	$DEBUG && echo "done."
      fi

      #########################
      # Relocation management #
      #########################
      
      if [ -e "$CONF" ]; then
        . "$CONF"
        if [ -n "$MLDONKEY_DIR" ] && [ -f "$MLDONKEY_DIR/downloads.ini" ]; then
          db_get mldonkey-server/reown_file 
          if [ "$RET" = "true" ] && ! dpkg-statoverride --list "$MLDONKEY_DIR" >/dev/null; then
            $DEBUG && echo -n "Reowning file of $MLDONKEY_DIR: "
            # BUG: should not use chown, should use dpkg-statoverride itself, but the owner is not always
            # the same. If i use the method suggested in the Debian Policy 10.9.1, i need to dynamically 
            # create a user, but this user should never be changed. The DP method will inject a new rules
            # in dpkg-statoverride which will made the above test always false for any further
            # upgrade/configure. With my method, only the user can set dpkg-statoverride rules to stop the 
            # reowning of a file... However i am not sure this is the best method to do so.
            /bin/chown -R $run_as_user:$mldonkey_group "$MLDONKEY_DIR"
            $DEBUG && echo "done."
          fi
        
          db_get mldonkey-server/mldonkey_move
          if [ "$RET" = "true" ] && [ "$new_mldonkey_dir" != "$MLDONKEY_DIR" ]; then
            $DEBUG && echo -n "Moving file of $MLDONKEY_DIR to $new_mldonkey_dir: "
            /bin/mv "--target-directory=$new_mldonkey_dir" "$MLDONKEY_DIR/*"
            $DEBUG && echo "done."
          fi
        fi
      fi
      
      #################
      # Downloads.ini #
      #################
 
      if [ -e "$new_mldonkey_dir/downloads.ini" ]; then
        $DEBUG && echo -n "Creating backup of $new_mldonkey_dir/downloads.ini: "
        /bin/cp -p -f "$new_mldonkey_dir/downloads.ini" "$new_mldonkey_dir/downloads.ini.dpkg"
        $DEBUG && echo "done."
      else
        $DEBUG && echo -n "Creating empty $new_mldonkey_dir/downloads.ini: "
        /bin/touch "$new_mldonkey_dir/downloads.ini"
        $DEBUG && echo "done."
      fi
         
      $DEBUG && echo -n "Writing new values to $new_mldonkey_dir/downloads.ini: "
      /usr/bin/mldonkey_options -f "$new_mldonkey_dir/downloads.ini" <<EOF
run_as_useruid=$run_as_useruid
run_as_user="$run_as_user"
client_name="$client_name"
enable_directconnect=$enable_directconnect
enable_opennap=$enable_opennap
enable_overnet=$enable_overnet
enable_soulseek=$enable_soulseek
enable_bittorrent=$enable_bittorrent
enable_gnutella=$enable_gnutella
enable_fasttrack=$enable_fasttrack
max_hard_upload_rate=$max_hard_upload_rate
max_hard_download_rate=$max_hard_download_rate
EOF
      $DEBUG && echo "done."
      
      #############
      # Files.ini #
      #############
      
      # Handling fasttrack file split here, better than in the mldonkey-server.init
      
      if [ -e "$new_mldonkey_dir/files.ini" ] \
        && [ ! -e "$new_mldonkey_dir/files.ini.fasttrack" ] \
        && /usr/bin/mldonkey_files --test Fasttrack -q -f0 "$new_mldonkey_dir/files.ini"; then
        echo "Correction of the Fasttrack problem (see /usr/share/doc/mldonkey-server/README.Debian)"
        echo -n "Splitting $new_mldonkey_dir/files.ini (backup in $new_mldonkey_dir/files.ini.fasttrack): "
        /usr/bin/mldonkey_files --split Fasttrack -f0 "$new_mldonkey_dir/files.ini" \
        -f1 "$new_mldonkey_dir/files.ini.fasttrack" \
        -f2 "$new_mldonkey_dir/files.ini" 
        echo "done."
      fi


      #############
      # Users.ini #
      #############
      
      if [ -e "$new_mldonkey_dir/downloads.ini" ] && \
        /usr/bin/mldonkey_users --test-users-section -q -f "$new_mldonkey_dir/downloads.ini"; then
        if [ -e "$new_mldonkey_dir/users.ini" ]; then
          echo "File $new_mldonkey_dir/users.ini exists and $new_mldonkey_dir/downloads.ini contains a \"users\" section, this is inconstitent."
          echo "Please user mldonkey_users(1) to strip the \"users\" section of $new_mldonkey_dir/downloads.ini."
        else
          # OK we have downloads.ini containing a "users" section, this is pre 2.5.28.1 
          # configuration, lets split it...
          $DEBUG && echo -n "Transferring \"users\" section  from file $new_mldonkey_dir/downloads.ini to $new_mldonkey_dir/users.ini: "
          /usr/bin/mldonkey_users --dump-users-section -q -f "$new_mldonkey_dir/downloads.ini" > "$new_mldonkey_dir/users.ini"
          /usr/bin/mldonkey_users --strip-users-section -q -f "$new_mldonkey_dir/downloads.ini" > "$new_mldonkey_dir/downloads.ini.tmp"
          mv -f "$new_mldonkey_dir/downloads.ini.tmp" "$new_mldonkey_dir/downloads.ini"
          $DEBUG && echo "done."
        fi
      fi
      
      if [  -n "$password" ]; then
        if [ -e "$new_mldonkey_dir/users.ini" ]; then
          $DEBUG && echo -n "Creating backup of $new_mldonkey_dir/users.ini: "
          /bin/cp -p -f "$new_mldonkey_dir/users.ini" "$new_mldonkey_dir/users.ini.dpkg"
          $DEBUG && echo "done."
        else
          $DEBUG && echo -n "Creating empty $new_mldonkey_dir/users.ini: "
          /bin/touch "$new_mldonkey_dir/users.ini"
          $DEBUG && echo "done."
        fi

	$DEBUG && echo -n "Registering admin password in $new_mldonkey_dir/users.ini: "
	/usr/bin/mldonkey_users --add admin -q -f "$new_mldonkey_dir/users.ini" -p $password
	$DEBUG && echo "done."
      fi
      
      ####################
      # Files permission #
      ####################

      for file in \
        "$new_mldonkey_dir"  \
        "/var/run" \
        "/var/log/mldonkey" \
        "$new_mldonkey_dir/downloads.ini" \
        "$new_mldonkey_dir/downloads.ini.dpkg" \
        "$new_mldonkey_dir/downloads.ini.old" \
        "$new_mldonkey_dir/downloads.ini.tmp" \
        "$new_mldonkey_dir/files.ini" \
        "$new_mldonkey_dir/files.ini.fasttrack"; do
        $DEBUG && echo -n "Changing owner and file permission of $file: "
        if ! dpkg-statoverride --list "$file" >/dev/null; then
          # BUG: cf dpkg-statoverride above
          if [ -e "$file" ]; then
            /bin/chown $run_as_user:$mldonkey_group $file
            $DEBUG && echo "done."
          else
            $DEBUG && echo "$file doesn't exist."
          fi
        else
          $DEBUG && echo "$file is listed in dpkg-statoverride."
        fi
      done

      for file in \
        "$new_mldonkey_dir/users.ini" \
        "$new_mldonkey_dir/users.ini.dpkg" \
        "$new_mldonkey_dir/users.ini.old" \
        "$new_mldonkey_dir/users.ini.tmp"; do
        $DEBUG && echo -n "Changing owner and file permission of $file: "
        if ! dpkg-statoverride --list "$file" >/dev/null; then
          # BUG: cf dpkg-statoverride above
          if [ -e "$file" ]; then
            /bin/chown $run_as_user:$mldonkey_group "$file"
            /bin/chmod 0600 "$file"
            $DEBUG && echo "done."
          else
            $DEBUG && echo "$file doesn't exist."
          fi
        else
          $DEBUG && echo "$file is listed in dpkg-statoverride."
        fi
      done
    fi

    ################################
    # /etc/default/mldonkey-server #
    ################################
    
    CONF_NEW=`/bin/tempfile`
    $DEBUG && echo -n "Writing new values to $CONF_NEW: "

    cat > "$CONF_NEW" <<EOF
# MLDonkey configuration
# This file is loaded by /etc/init.d/mldonkey-server
# This file is managed using ucf(1)

MLDONKEY_DIR=$new_mldonkey_dir
MLDONKEY_GROUP=$mldonkey_group
MLDONKEY_UMASK=$mldonkey_umask
MAX_ALIVE=$max_alive
LAUNCH_AT_STARTUP=$launch_at_startup
MLDONKEY_NICENESS=$mldonkey_niceness
EOF

    ucf "$CONF_NEW" "$CONF"

    $DEBUG && echo "done."
  ;;

  abort-upgrade|abort-remove|abort-deconfigure)
  ;;

  *) 
    echo "postinst called with unknown argument \`$1'" >&2
    exit 1
  ;;
esac

db_stop

# For the rest
# Automatically added by dh_installmenu
if [ "$1" = "configure" ] && [ -x "`which update-menus 2>/dev/null`" ]; then
	update-menus
fi
# End automatically added section
# Automatically added by dh_installinit
if [ -x "/etc/init.d/mldonkey-server" ]; then
	update-rc.d mldonkey-server start 98 2 3 4 5 . stop 20 0 1 6 . >/dev/null
	if [ -x "`which invoke-rc.d 2>/dev/null`" ]; then
		invoke-rc.d mldonkey-server start || exit $?
	else
		/etc/init.d/mldonkey-server start || exit $?
	fi
fi
# End automatically added section


MfG
Nameless
 
Zuletzt bearbeitet von einem Moderator:
sieht eigentlich gut aus ... und die /etc/init.d/mldonkey-server ?

P.S.: CODE-Tags sind handlicher als QUOTE für Coding ;)
 
Hier ist die mldonkey-server:

Code:
#!/bin/sh
#
# Original file :
#    Written by Miquel van Smoorenburg <miquels@cistron.nl>.
#    Modified for Debian GNU/Linux
#    by Ian Murdock <imurdock@gnu.ai.mit.edu>.
#
# Version:  @(#)skeleton  1.9.1  08-Apr-2002  miquels@cistron.nl
#
# 
# This file has been rewritten by Sylvain LE GALL <sylvain.le-gall@m4x.org>
# for mldonkey-package.

PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
WRAPPER=/usr/bin/mldonkey_server
NAME=mlnet
DESC="MLDonkey"
CONFIG=/etc/default/mldonkey-server
PIDFILE=/var/run/$NAME.pid

test -x $WRAPPER || exit 0

test -e $CONFIG || exit 0

set -e

. $CONFIG

WRAPPER_OPTIONS=""

# Set the pidfile
WRAPPER_OPTIONS="$WRAPPER_OPTIONS --pidfile $PIDFILE"

# Set configuration value, from CONFIG
if [ -n "$MLDONKEY_DIR" ]; then
  WRAPPER_OPTIONS="$WRAPPER_OPTIONS --chdir $MLDONKEY_DIR"
fi

if [ -n "$MLDONKEY_GROUP" ]; then
  WRAPPER_OPTIONS="$WRAPPER_OPTIONS --chgid $MLDONKEY_GROUP"
fi

if [ -n "$MLDONKEY_UMASK" ]; then
  WRAPPER_OPTIONS="$WRAPPER_OPTIONS --umask $MLDONKEY_UMASK"
fi

if [ -n "$MLDONKEY_NICENESS" ]; then
  WRAPPER_OPTIONS="$WRAPPER_OPTIONS --nice $MLDONKEY_NICENESS"
fi

if [ -n "$MAX_ALIVE" ]; then
  WRAPPER_OPTIONS="$WRAPPER_OPTIONS --max-alive $MAX_ALIVE"
fi

case "$1" in
  start|force-start)
    echo -n "Starting $DESC: $NAME"

    if [ "x$LAUNCH_AT_STARTUP" != "xtrue" ] && [ "x$1" = "xstart" ]; then
      echo " configuration file prevent $NAME to be started (use force-start)."
      exit 0
    fi

    if [ -z "$MLDONKEY_DIR" ] || [ ! -d "$MLDONKEY_DIR" ]; then
      if [ -z "$MLDONKEY_DIR" ]; then
        MLDONKEY_DIR="(unset)"
      fi
      echo " $MLDONKEY_DIR is not a valid directory."
      exit 1
    fi

    if [ ! -f "$MLDONKEY_DIR/downloads.ini" ]; then
      echo " $MLDONKEY_DIR/downloads.ini is not a valid file."
      exit 1
    fi

    USER=`/usr/bin/stat --format="%U" "$MLDONKEY_DIR/downloads.ini"`
    WRAPPER_OPTIONS="$WRAPPER_OPTIONS --chuid $USER"
   
    # export MLDONKEY_CHROOT=$MLDONKEY_DIR
    
    install -o mldonkey -g mldoney -m 755 -f $PIDFILE
    start-stop-daemon --start --pidfile $PIDFILE \
    --exec $WRAPPER -- --start --daemon $WRAPPER_OPTIONS

    echo "."
  ;;
  stop)
    echo -n "Stopping $DESC: $NAME"
    start-stop-daemon --stop --pidfile $PIDFILE
    echo "."
  ;;
  reload)
    echo -n "Reloading $DESC: $NAME"
    $WRAPPER --restart --quiet $WRAPPER_OPTIONS
    echo "."
  ;;
  force-reload|restart)
    $0 stop
    sleep 1
    $0 start
  ;;
  *)
    echo "Usage: $0 {start|stop|restart|force-reload|force-start}" >&2
    exit 1
  ;;
esac

exit 0


PS: Was mir bei CODE-Tags fehlt, ist das ich im Gegensatz zu QUOTE-Tags nicht den Urheber vom zitierten Text im Tag-Befehl mit angeben kann, wie z.B. bei QUOTE=IrgendeinUrheber was dann automatisch zu "Zitat von IrgendeinUrheber" umgewandelt wird.


MfG
Nameless
 
Code:
    # export MLDONKEY_CHROOT=$MLDONKEY_DIR
    
[COLOR="Red"]    install -o mldonkey -g mldoney -m 755 -f $PIDFILE[/COLOR]
    start-stop-daemon --start --pidfile $PIDFILE \
    --exec $WRAPPER -- --start --daemon $WRAPPER_OPTIONS

Kommentier mal die Zeile aus, d.h. einfach ein # davor schreiben ... und dann nochmal
Code:
apt-get install -f
 
Nach dem auskommentieren und ausführen von apt-get install -f kommt folgendes:
Paketlisten werden gelesen... Fertig
Abhängigkeitsbaum wird aufgebaut... Fertig
0 aktualisiert, 0 neu installiert, 0 zu entfernen und 0 nicht aktualisiert.
1 nicht vollständig installiert oder entfernt.
Es müssen 0B Archive geholt werden.
Nach dem Auspacken werden 0B Plattenplatz zusätzlich benutzt.
Richte mldonkey-server ein (2.7.1-2ubuntu2) ...
Starting MLDonkey: mlnet.

Hat es jetzt endlich funktioniert?


MfG
Nameless
 
Code:
ps ax
sollte Dir sagen, ob der Mldonkey-Server (mlnet) läuft ... und ich denke mal, das tut er ...
 
Folgendes wird auf ps ax angezeigt:
Code:
 PID TTY      STAT   TIME COMMAND
    1 ?        S      0:01 init [2]
    2 ?        SN     0:00 [ksoftirqd/0]
    3 ?        S      0:00 [watchdog/0]
    4 ?        S<     0:00 [events/0]
    5 ?        S<     0:00 [khelper]
    6 ?        S<     0:00 [kthread]
    8 ?        S<     0:00 [kblockd/0]
    9 ?        S<     0:00 [kacpid]
  153 ?        S      0:00 [pdflush]
  154 ?        S      0:00 [pdflush]
  156 ?        S<     0:00 [aio/0]
  155 ?        S      0:00 [kswapd0]
  743 ?        S<     0:00 [kseriod]
 1757 ?        S<     0:00 [ata/0]
 1758 ?        S<     0:00 [ata_hotplug/0]
 1761 ?        S<     0:00 [scsi_eh_0]
 1762 ?        S<     0:00 [scsi_eh_1]
 1923 ?        S<     0:00 [khubd]
 1930 ?        S      0:00 [khpsbpkt]
 1938 ?        S      0:00 [knodemgrd_0]
 2029 ?        S      0:00 [kjournald]
 2122 ?        S<     0:00 [kacpid-work-0]
 2264 ?        S<s    0:00 /sbin/udevd --daemon
 3133 ?        S      0:00 [shpchpd_event]
 3534 ?        S<s    0:00 dhclient3 -pf /var/run/dhclient.eth0.pid -lf /var/lib
 3632 ?        S      0:00 [kjournald]
 4162 ?        Ss     0:00 /usr/sbin/acpid -c /etc/acpi/events -s /var/run/acpid
 4252 ?        Ss     0:00 /sbin/syslogd -u syslog
 4278 ?        Ss     0:00 /bin/dd bs 1 if /proc/kmsg of /var/run/klogd/kmsg
 4280 ?        Ss     0:00 /sbin/klogd -P /var/run/klogd/kmsg
 4302 ?        Ss     0:00 /usr/sbin/gdm
 4303 ?        S      0:00 /usr/sbin/gdm
 4306 tty7     Rs+    6:55 /usr/bin/X :0 -br -audit 0 -auth /var/lib/gdm/:0.Xaut
 4335 ?        Ssl    0:00 /usr/sbin/hpiod
 4350 ?        S      0:00 python /usr/sbin/hpssd
 4397 ?        Ss     0:01 /usr/sbin/cupsd
 4422 ?        Ss     0:00 /usr/bin/dbus-daemon --system
 4437 ?        Ss     0:01 /usr/sbin/hald
 4438 ?        S      0:00 hald-runner
 4444 ?        S      0:00 /usr/lib/hal/hald-addon-acpi
 4494 ?        S      0:00 /usr/lib/hal/hald-addon-keyboard
 4505 ?        S      0:00 /usr/lib/hal/hald-addon-storage
 4506 ?        S      0:00 /usr/lib/hal/hald-addon-storage
 4508 ?        S      0:00 /usr/lib/hal/hald-addon-storage
 4509 ?        S      0:00 /usr/lib/hal/hald-addon-storage
 4593 ?        SLs    0:00 /usr/sbin/ntpd -p /var/run/ntpd.pid -u 113:113
 4609 ?        Ss     0:00 hcid: processing events
 4614 ?        Ss     0:00 /usr/sbin/sdpd
 4623 ?        S<     0:00 [krfcommd]
 4637 ?        Ss     0:00 /sbin/mdadm -F -i /var/run/mdadm.pid -m root -f -s
 4671 ?        Ss     0:00 /usr/sbin/atd
 4684 ?        Ss     0:00 /usr/sbin/cron
 4762 tty1     Ss+    0:00 /sbin/getty 38400 tty1
 4763 tty2     Ss+    0:00 /sbin/getty 38400 tty2
 4764 tty3     Ss+    0:00 /sbin/getty 38400 tty3
 4765 tty4     Ss+    0:00 /sbin/getty 38400 tty4
 4766 tty5     Ss+    0:00 /sbin/getty 38400 tty5
 4769 tty6     Ss+    0:00 /sbin/getty 38400 tty6
 4790 ?        Ss     0:00 x-session-manager
 4832 ?        Ss     0:00 /usr/bin/ssh-agent /usr/bin/dbus-launch --exit-with-s
 4835 ?        S      0:00 /usr/bin/dbus-launch --exit-with-session x-session-ma
 4836 ?        Ss     0:00 dbus-daemon --fork --print-pid 8 --print-address 6 --
 4838 ?        S      0:00 /usr/lib/libgconf2-4/gconfd-2 5
 4841 ?        S      0:00 /usr/bin/gnome-keyring-daemon
 4843 ?        Ss     0:00 /usr/lib/bonobo-activation/bonobo-activation-server -
 4845 ?        Sl     0:01 /usr/lib/control-center/gnome-settings-daemon --oaf-a
 4847 ?        Ss     0:00 /usr/bin/esd -terminate -nobeeps -as 1 -spawnfd 18
 4854 ?        Ss     0:12 /usr/bin/metacity --sm-client-id=default0
 4860 ?        Ssl    0:12 gnome-panel --sm-client-id default1
 4862 ?        Rsl    0:08 nautilus --no-default-window --sm-client-id default2
 4867 ?        Ss     0:00 gnome-volume-manager --sm-client-id default4
 4873 ?        Ss     0:00 update-notifier
 4878 ?        Sl     0:00 /usr/lib/gnome-vfs-2.0/gnome-vfs-daemon --oaf-activat
 4880 ?        Ss     0:27 gnome-cups-icon --sm-client-id default3
 4893 ?        Ss     0:00 gnome-power-manager
 4895 ?        Rl     0:00 /usr/lib/gnome-applets/trashapplet --oaf-activate-iid
 4906 ?        S      0:00 /usr/lib/nautilus-cd-burner/mapping-daemon
 4912 ?        Sl     0:02 /usr/lib/gnome-panel/clock-applet --oaf-activate-iid=
 4914 ?        S      0:00 /usr/lib/gnome-applets/mixer_applet2 --oaf-activate-i
 4920 ?        Sl     0:21 evolution --component=mail
 4922 ?        Sl     0:00 /usr/lib/evolution/evolution-data-server-1.6 --oaf-ac
 4927 ?        Sl     0:00 /usr/lib/evolution/2.6/evolution-exchange-storage --o
 4934 ?        Sl     0:00 /usr/lib/evolution/2.6/evolution-alarm-notify --oaf-a
 4958 ?        Ss     0:02 gnome-screensaver
13112 ?        Sl     0:57 /usr/lib/firefox/firefox-bin -a firefox [url]http://bugzil[/url]
18497 ?        Sl     0:00 gnome-terminal
18499 ?        S      0:00 gnome-pty-helper
18500 pts/0    Ss     0:00 bash
18518 pts/0    R+     0:00 ps ax

Von mlnet finde ich leider nichts:(
Heißt das jetzt, dass der MLdonkey-Server doch nicht läuft??( :hilfe2:


MfG
Nameless
 
Hmmm ...

Was passiert denn, wenn Du
Code:
sudo /etc/init.d/mldonkey-server restart
eingibst?
 
Auf den Befehl sudo /etc/init.d/mldonkey-server restart erscheint folgendes:

Code:
Stopping MLDonkey: mlnetNo process in pidfile `/var/run/mlnet.pid' found running ; none killed.

...und auf ps ax folgendes:
Code:
  PID TTY      STAT   TIME COMMAND
    1 ?        S      0:01 init [2]
    2 ?        SN     0:00 [ksoftirqd/0]
    3 ?        S      0:00 [watchdog/0]
    4 ?        S<     0:00 [events/0]
    5 ?        S<     0:00 [khelper]
    6 ?        S<     0:00 [kthread]
    8 ?        S<     0:00 [kblockd/0]
    9 ?        S<     0:00 [kacpid]
  153 ?        S      0:00 [pdflush]
  154 ?        S      0:00 [pdflush]
  156 ?        S<     0:00 [aio/0]
  155 ?        S      0:00 [kswapd0]
  743 ?        S<     0:00 [kseriod]
 1757 ?        S<     0:00 [ata/0]
 1758 ?        S<     0:00 [ata_hotplug/0]
 1761 ?        S<     0:00 [scsi_eh_0]
 1762 ?        S<     0:00 [scsi_eh_1]
 1923 ?        S<     0:00 [khubd]
 1930 ?        S      0:00 [khpsbpkt]
 1938 ?        S      0:00 [knodemgrd_0]
 2029 ?        S      0:00 [kjournald]
 2263 ?        S<s    0:00 /sbin/udevd --daemon
 3116 ?        S      0:00 [shpchpd_event]
 3372 ?        S<s    0:00 dhclient3 -pf /var/run/dhclient.eth0.pid -lf /var/lib 3631 ?        S      0:00 [kjournald]
 4159 ?        Ss     0:00 /usr/sbin/acpid -c /etc/acpi/events -s /var/run/acpid 4275 ?        Ss     0:00 /bin/dd bs 1 if /proc/kmsg of /var/run/klogd/kmsg
 4277 ?        Ss     0:00 /sbin/klogd -P /var/run/klogd/kmsg
 4299 ?        Ss     0:00 /usr/sbin/gdm
 4300 ?        S      0:00 /usr/sbin/gdm
 4303 tty7     Rs+    0:42 /usr/bin/X :0 -br -audit 0 -auth /var/lib/gdm/:0.Xaut 4332 ?        Ssl    0:00 /usr/sbin/hpiod
 4347 ?        S      0:00 python /usr/sbin/hpssd
 4419 ?        Ss     0:00 /usr/bin/dbus-daemon --system
 4434 ?        Ss     0:00 /usr/sbin/hald
 4435 ?        S      0:00 hald-runner
 4441 ?        S      0:00 /usr/lib/hal/hald-addon-acpi
 4491 ?        S      0:00 /usr/lib/hal/hald-addon-keyboard
 4502 ?        S      0:00 /usr/lib/hal/hald-addon-storage
 4503 ?        S      0:00 /usr/lib/hal/hald-addon-storage
 4505 ?        S      0:00 /usr/lib/hal/hald-addon-storage
 4506 ?        S      0:00 /usr/lib/hal/hald-addon-storage
 4590 ?        SLs    0:00 /usr/sbin/ntpd -p /var/run/ntpd.pid -u 113:113
 4606 ?        Ss     0:00 hcid: processing events
 4610 ?        Ss     0:00 /usr/sbin/sdpd
 4625 ?        S<     0:00 [krfcommd]
 4638 ?        Ss     0:00 /sbin/mdadm -F -i /var/run/mdadm.pid -m root -f -s
 4672 ?        Ss     0:00 /usr/sbin/atd
 4685 ?        Ss     0:00 /usr/sbin/cron
 4763 tty1     Ss+    0:00 /sbin/getty 38400 tty1
 4764 tty2     Ss+    0:00 /sbin/getty 38400 tty2
 4765 tty3     Ss+    0:00 /sbin/getty 38400 tty3
 4766 tty4     Ss+    0:00 /sbin/getty 38400 tty4
 4767 tty5     Ss+    0:00 /sbin/getty 38400 tty5
 4768 tty6     Ss+    0:00 /sbin/getty 38400 tty6
 4830 ?        Ss     0:00 x-session-manager
 4872 ?        Ss     0:00 /usr/bin/ssh-agent /usr/bin/dbus-launch --exit-with-s 4875 ?        S      0:00 /usr/bin/dbus-launch --exit-with-session x-session-ma 4876 ?        Ss     0:00 dbus-daemon --fork --print-pid 8 --print-address 6 -- 4893 ?        S      0:00 /usr/lib/libgconf2-4/gconfd-2 5
 4930 ?        SNs    0:00 /usr/sbin/cupsd
 4936 ?        S      0:00 /usr/bin/gnome-keyring-daemon
 4938 ?        Ss     0:00 /usr/lib/bonobo-activation/bonobo-activation-server - 4940 ?        Sl     0:00 /usr/lib/control-center/gnome-settings-daemon --oaf-a 4942 ?        Ss     0:00 /usr/bin/esd -terminate -nobeeps -as 1 -spawnfd 18
 4949 ?        Ss     0:02 /usr/bin/metacity --sm-client-id=default0
 4955 ?        Ssl    0:01 gnome-panel --sm-client-id default1
 4957 ?        Ssl    0:00 nautilus --no-default-window --sm-client-id default2
 4960 ?        Ss     0:00 gnome-volume-manager --sm-client-id default4
 4969 ?        Sl     0:00 /usr/lib/gnome-vfs-2.0/gnome-vfs-daemon --oaf-activat 4971 ?        Ss     0:00 update-notifier
 4975 ?        Ss     0:00 gnome-cups-icon --sm-client-id default3
 4987 ?        Sl     0:00 /usr/lib/gnome-applets/trashapplet --oaf-activate-iid 4988 ?        Ss     0:00 gnome-power-manager
 5000 ?        S      0:00 /usr/lib/nautilus-cd-burner/mapping-daemon
 5004 ?        S      0:00 /usr/lib/gnome-panel/clock-applet --oaf-activate-iid= 5010 ?        S      0:00 /usr/lib/gnome-applets/mixer_applet2 --oaf-activate-i 5028 ?        Sl     0:16 evolution --component=mail
 5032 ?        Sl     0:00 /usr/lib/evolution/evolution-data-server-1.6 --oaf-ac 5035 ?        Sl     0:00 /usr/lib/evolution/2.6/evolution-exchange-storage --o 5044 ?        Sl     0:00 /usr/lib/evolution/2.6/evolution-alarm-notify --oaf-a 5069 ?        Ss     0:00 gnome-screensaver
 5152 ?        SNs    0:00 /sbin/syslogd -u syslog
 5178 ?        S      0:00 /usr/bin/python -c ?import sys?sys.path.insert(0, '/u 5186 ?        Z      0:00 [gnome-open] <defunct>
 5188 ?        Sl     0:22 /usr/lib/firefox/firefox-bin -a firefox https://launc 5486 ?        Sl     0:00 gnome-terminal
 5487 ?        S      0:00 gnome-pty-helper
 5488 pts/0    Ss     0:00 bash
 5508 pts/0    R+     0:00 ps ax


MfG
Nameless
 
Zuletzt bearbeitet:
O.k. ... wir editieren mal noch etwas ...:
/etc/init.d/mldonkey-server
Code:
    # export MLDONKEY_CHROOT=$MLDONKEY_DIR
    
    install -o mldonkey -g mldoney -m 755 [COLOR="Red"]-f[/COLOR] $PIDFILE
    start-stop-daemon --start --pidfile $PIDFILE \
    --exec $WRAPPER -- --start --daemon $WRAPPER_OPTIONS
Entkommentier mal wieder die Zeile und entfern mal bloß das "-f".
Anschließen löschst Du die Datei /var/run/mlnet.pid und versuchst nochmal nen restart ...
 
Anschließen löschst Du die Datei /var/run/mlnet.pid und versuchst nochmal nen restart ...
Wie bereits geschrieben (s.o.), die Datei /var/run/mlnet.pid gibts nicht auf meinem Computer!

Nach dem ändern, auskommentieren und einem restart kommt wieder:
Code:
Stopping MLDonkey: mlnetNo process in pidfile `/var/run/mlnet.pid' found running; none killed.


MfG
Nameless
 
Und es läuft trotzdem kein mlnet oder mldonkey-server Prozess? Sehr seltsam ...
 
Anscheinend leider nicht.
Was kann man jetzt noch machen?


MfG
Nameless
 
O.k. ... da er nicht läuft, gibt es bei
Code:
/etc/init.d/mldonkey-server start
irgendwelche Ausgaben?
Gibt es die Dateien
/usr/bin/mldonkey_server
/etc/default/mldonkey-server
?

"/etc/init.d/mldonkey-server" sollte jetzt so aussehen:
Code:
#!/bin/sh
#
# Original file :
#    Written by Miquel van Smoorenburg <miquels@cistron.nl>.
#    Modified for Debian GNU/Linux
#    by Ian Murdock <imurdock@gnu.ai.mit.edu>.
#
# Version:  @(#)skeleton  1.9.1  08-Apr-2002  miquels@cistron.nl
#
# 
# This file has been rewritten by Sylvain LE GALL <sylvain.le-gall@m4x.org>
# for mldonkey-package.

PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
WRAPPER=/usr/bin/mldonkey_server
NAME=mlnet
DESC="MLDonkey"
CONFIG=/etc/default/mldonkey-server
PIDFILE=/var/run/$NAME.pid

test -x $WRAPPER || exit 0

test -e $CONFIG || exit 0

set -e

. $CONFIG

WRAPPER_OPTIONS=""

# Set the pidfile
WRAPPER_OPTIONS="$WRAPPER_OPTIONS --pidfile $PIDFILE"

# Set configuration value, from CONFIG
if [ -n "$MLDONKEY_DIR" ]; then
  WRAPPER_OPTIONS="$WRAPPER_OPTIONS --chdir $MLDONKEY_DIR"
fi

if [ -n "$MLDONKEY_GROUP" ]; then
  WRAPPER_OPTIONS="$WRAPPER_OPTIONS --chgid $MLDONKEY_GROUP"
fi

if [ -n "$MLDONKEY_UMASK" ]; then
  WRAPPER_OPTIONS="$WRAPPER_OPTIONS --umask $MLDONKEY_UMASK"
fi

if [ -n "$MLDONKEY_NICENESS" ]; then
  WRAPPER_OPTIONS="$WRAPPER_OPTIONS --nice $MLDONKEY_NICENESS"
fi

if [ -n "$MAX_ALIVE" ]; then
  WRAPPER_OPTIONS="$WRAPPER_OPTIONS --max-alive $MAX_ALIVE"
fi

case "$1" in
  start|force-start)
    echo -n "Starting $DESC: $NAME"

    if [ "x$LAUNCH_AT_STARTUP" != "xtrue" ] && [ "x$1" = "xstart" ]; then
      echo " configuration file prevent $NAME to be started (use force-start)."
      exit 0
    fi

    if [ -z "$MLDONKEY_DIR" ] || [ ! -d "$MLDONKEY_DIR" ]; then
      if [ -z "$MLDONKEY_DIR" ]; then
        MLDONKEY_DIR="(unset)"
      fi
      echo " $MLDONKEY_DIR is not a valid directory."
      exit 1
    fi

    if [ ! -f "$MLDONKEY_DIR/downloads.ini" ]; then
      echo " $MLDONKEY_DIR/downloads.ini is not a valid file."
      exit 1
    fi

    USER=`/usr/bin/stat --format="%U" "$MLDONKEY_DIR/downloads.ini"`
    WRAPPER_OPTIONS="$WRAPPER_OPTIONS --chuid $USER"
   
    # export MLDONKEY_CHROOT=$MLDONKEY_DIR
    
    install -o mldonkey -g mldoney -m 755 $PIDFILE
    start-stop-daemon --start --pidfile $PIDFILE \
    --exec $WRAPPER -- --start --daemon $WRAPPER_OPTIONS

    echo "."
  ;;
  stop)
    echo -n "Stopping $DESC: $NAME"
    start-stop-daemon --stop --pidfile $PIDFILE
    echo "."
  ;;
  reload)
    echo -n "Reloading $DESC: $NAME"
    $WRAPPER --restart --quiet $WRAPPER_OPTIONS
    echo "."
  ;;
  force-reload|restart)
    $0 stop
    sleep 1
    $0 start
  ;;
  *)
    echo "Usage: $0 {start|stop|restart|force-reload|force-start}" >&2
    exit 1
  ;;
esac

exit 0
 
O.k. ... da er nicht läuft, gibt es bei
Code:
/etc/init.d/mldonkey-server start
irgendwelche Ausgaben?
Ja, folgende:
Code:
Starting MLDonkey: mlnetinstall: Fehlender Zieldatei-Operand hinter „/var/run/ml net.pid“
„install --help“ gibt weitere Informationen.


Gibt es die Dateien
/usr/bin/mldonkey_server
/etc/default/mldonkey-server
?
Ja, beide Dateien sind vorhanden.


"/etc/init.d/mldonkey-server" sollte jetzt so aussehen:
Code:
#!/bin/sh
#
# Original file :
#    Written by Miquel van Smoorenburg <miquels@cistron.nl>.
#    Modified for Debian GNU/Linux
#    by Ian Murdock <imurdock@gnu.ai.mit.edu>.
#
# Version:  @(#)skeleton  1.9.1  08-Apr-2002  miquels@cistron.nl
#
# 
# This file has been rewritten by Sylvain LE GALL <sylvain.le-gall@m4x.org>
# for mldonkey-package.

PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
WRAPPER=/usr/bin/mldonkey_server
NAME=mlnet
DESC="MLDonkey"
CONFIG=/etc/default/mldonkey-server
PIDFILE=/var/run/$NAME.pid

test -x $WRAPPER || exit 0

test -e $CONFIG || exit 0

set -e

. $CONFIG

WRAPPER_OPTIONS=""

# Set the pidfile
WRAPPER_OPTIONS="$WRAPPER_OPTIONS --pidfile $PIDFILE"

# Set configuration value, from CONFIG
if [ -n "$MLDONKEY_DIR" ]; then
  WRAPPER_OPTIONS="$WRAPPER_OPTIONS --chdir $MLDONKEY_DIR"
fi

if [ -n "$MLDONKEY_GROUP" ]; then
  WRAPPER_OPTIONS="$WRAPPER_OPTIONS --chgid $MLDONKEY_GROUP"
fi

if [ -n "$MLDONKEY_UMASK" ]; then
  WRAPPER_OPTIONS="$WRAPPER_OPTIONS --umask $MLDONKEY_UMASK"
fi

if [ -n "$MLDONKEY_NICENESS" ]; then
  WRAPPER_OPTIONS="$WRAPPER_OPTIONS --nice $MLDONKEY_NICENESS"
fi

if [ -n "$MAX_ALIVE" ]; then
  WRAPPER_OPTIONS="$WRAPPER_OPTIONS --max-alive $MAX_ALIVE"
fi

case "$1" in
  start|force-start)
    echo -n "Starting $DESC: $NAME"

    if [ "x$LAUNCH_AT_STARTUP" != "xtrue" ] && [ "x$1" = "xstart" ]; then
      echo " configuration file prevent $NAME to be started (use force-start)."
      exit 0
    fi

    if [ -z "$MLDONKEY_DIR" ] || [ ! -d "$MLDONKEY_DIR" ]; then
      if [ -z "$MLDONKEY_DIR" ]; then
        MLDONKEY_DIR="(unset)"
      fi
      echo " $MLDONKEY_DIR is not a valid directory."
      exit 1
    fi

    if [ ! -f "$MLDONKEY_DIR/downloads.ini" ]; then
      echo " $MLDONKEY_DIR/downloads.ini is not a valid file."
      exit 1
    fi

    USER=`/usr/bin/stat --format="%U" "$MLDONKEY_DIR/downloads.ini"`
    WRAPPER_OPTIONS="$WRAPPER_OPTIONS --chuid $USER"
   
    # export MLDONKEY_CHROOT=$MLDONKEY_DIR
    
    install -o mldonkey -g mldoney -m 755 $PIDFILE
    start-stop-daemon --start --pidfile $PIDFILE \
    --exec $WRAPPER -- --start --daemon $WRAPPER_OPTIONS

    echo "."
  ;;
  stop)
    echo -n "Stopping $DESC: $NAME"
    start-stop-daemon --stop --pidfile $PIDFILE
    echo "."
  ;;
  reload)
    echo -n "Reloading $DESC: $NAME"
    $WRAPPER --restart --quiet $WRAPPER_OPTIONS
    echo "."
  ;;
  force-reload|restart)
    $0 stop
    sleep 1
    $0 start
  ;;
  *)
    echo "Usage: $0 {start|stop|restart|force-reload|force-start}" >&2
    exit 1
  ;;
esac

exit 0
Ja, genau so sieht meine /etc/init.d/mldonkey-server auch aus.


MfG
Nameless
 
*arg* ... ich mag das Ubuntu-Gefrikel nicht ...
Ersetzt mal die /etc/init.d/mldonkey-server mit der hier angehängten ...
(das .txt am Ende bitte entfernen ;) )
 

Anhänge

  • mldonkey-server.txt
    3,1 KB · Aufrufe: 25
OK, hab ich gemacht.

Dann wieder ein sudo /etc/init.d/mldonkey-server restart? Kein Problem, aber darauf kommt jetzt folgendes:
Code:
sudo: /etc/init.d/mldonkey-server: command not found


MfG
Nameless
 
Dann hast Du beim ersetzen was falsch gemacht ... oder halt das ".txt" nicht entfernt ...

Eventuell ist auch noch ein
Code:
sudo chmod 755 /etc/init.d/mldonkey-server
sudo chown root:root /etc/init.d/mldonkey-server
nötig ... je nachdem, wie Du "ersetzt" hast ...
 
Danke für den Hinweis!:)) Vermutlich lag es an den Dateirechten.:think:

Auf jeden Fall kommt nun nach der Eingabe der Befehle
sudo chmod 755 /etc/init.d/mldonkey-server,
sudo chown root:root /etc/init.d/mldonkey-server
und einem erneuten sudo /etc/init.d/mldonkey-server restart folgendes:
Code:
Stopping MLDonkey: mlnetNo process in pidfile `/var/run/mldonkey/mlnet.pid' foun d running; none killed.
.
Starting MLDonkey: mlnet file[s] not owned by user 107 or group 1001: /var/run/m ldonkey -- reown it first


MfG
Nameless
 
Code:
sudo chown 107:1001 /etc/init.d/mldonkey-server
 

Ähnliche Themen

grub-pc Probleme bei upgrade

Problem bei apt-get upgrade (Kali 2.0)

samba4 auf ubuntu 12.04.3 server

hotkey-setup

Updatefehler acpid & acpi-support

Zurück
Oben