PDA

Archiv verlassen und diese Seite im Standarddesign anzeigen : NFS Homeverzeichnisse sind zu langsam



tomiondrums
13.10.07, 11:27
Hi!
Auf meinem Debian-Server läuft NFS und zur zentralen Benutzerverwaltung verwende ich NIS. An und für sich läuft das ganze auch ganz ordentlich, nur habe ich vor ein paar Wochen angefangen mir einen neuen Gentoo Client aufzusetzen. Auch hier konnte ich problemlos nach der Einrichtung des NIS-Clients und der Anpassung der /etc/fstab mit den Benutzern, die vom Server exportiert werden hantieren. Nur hat offenbar die KDE und alle Programme, die im Homeverzeichis ein .*-Verzeichnis verwenden (also auch Mozilla, Eclipse etc.) ein Problem mit den NFS-Homeverzeichnissen. Jenes äußert sich in extremen Gewindigkeitseinbußen. Ein Start der KDE dauert als root (Homeverzeichnis auf der Festplatte) ca. 13s, jedoch mit einem, per NIS-importieten Benutzer ca. 6-7 Minuten - teilweise sogar noch länger. Das Kopieren von größeren Dateien aus oder in die NFS-Homeverzeichnisse geht jedoch ziemlich flott vonstatten (mit 10 - 13MB/s).

Mit den NFS-Optionen sync/async und subtree_check/no_subtree_check habe ich bereits diverse Versuche unternommen, von denen jedoch keiner eine Besserung gebracht hat.

Die /etc/exports auf dem Server sieht folgendermaßen aus:


/pub/users/projekte 192.168.10.0/24(rw,async,no_root_squash,no_subtree_check)
/pub/users/projekte 192.168.11.0/24(rw,async,no_root_squash,no_subtree_check)

/home 192.168.10.0/24(rw,async,no_root_squash,no_subtree_check)
/home 192.168.11.0/24(rw,async,no_root_squash,no_subtree_check)



/pub/users/musik/mp3 server(rw,sync,subtree_check)
/pub/users/musik/mp3 pcanja(rw,sync,no_root_squash,subtree_check)
/pub/users/musik/mp3 pcnote(rw,sync,no_root_squash,subtree_check)
/pub/users/musik/mp3 dual(rw,sync,no_root_squash,subtree_check)
/pub/users/musik/mp3 pctomi(rw,sync,subtree_check)
/pub/users/musik/mp3 scenic(rw,sync,subtree_check)

/pub/users/bilder dual(rw,sync,no_root_squash,subtree_check)
/pub/users/bilder pcanja(rw,sync,no_root_squash,subtree_check)
/pub/users/bilder pcnote(rw,sync,no_root_squash,subtree_check)
/pub/users/bilder scenic(rw,sync,no_root_squash,subtree_check)
/pub/users/bilder pctomi(rw,sync,no_root_squash,subtree_check)
/pub/users/bilder server(rw,sync,no_root_squash,subtree_check)

/pub backup(rw,async,no_root_squash,no_subtree_check)
/pub dual(rw,async,no_root_squash,no_subtree_check)


Die Clientseitige /etc/fstab:


/dev/hda2 / ext3 noatime 0 1
/dev/hda1 /boot ext2 noauto,noatime 0 1
server:/pub/users /home nfs nosuid,rw,async 0 0
server:/pub/users/musik /mnt/musik nfs nosuid,rw,async 0 0

Ein weiterer Client (läuft unter Debian, verwendet ebenfalls NIS und NFS-Homeverzeichnisse) funktioniert diesbezüglich wunderbar, d.h. KDE und Programme starten in kürzester Zeit.

Hatte von euch schonmal jemand so ein Problem? Was kann ich dagegen tun?

bla!zilla
14.10.07, 17:57
Das riecht nach Probleme mit dem Locking. Bitte etwas mehr Details zu dem Debian Server und poste bitte Logs, speziell /var/log/messages.

tomiondrums
16.10.07, 09:50
Hi bla!zilla!
Sieht nach nem Volltreffer aus!
Ich hab auf dein Anraten hin mal die Logs untersucht jeweils vom Server (ist übrigens ein Debian Lenny, Hostname server) und vom Client. Dazu hab ich am Server jeweils die /var/log/messages und die /var/log/syslog, sowie die messages auf dem Client "ausgeputzt" mich als nicht-root-User angemeldet und mal die KDE gestartet.
Das Ganze dauerte mehr als neun Minuten und brachte in den Sever-Logs keine Auffälligkeiten zutage, aber die Logs vom Client (Hostname dual)
machen neugierig:


Oct 16 09:21:09 dual statd: server localhost not responding, timed out
Oct 16 09:21:09 dual lockd: cannot monitor server
Oct 16 09:21:09 dual lockd: failed to monitor server
Oct 16 09:21:09 dual statd: server localhost not responding, timed out
Oct 16 09:21:09 dual lockd: cannot monitor server
Oct 16 09:21:09 dual lockd: failed to monitor server
Oct 16 09:21:39 dual statd: server localhost not responding, timed out
Oct 16 09:21:39 dual lockd: cannot monitor server
Oct 16 09:21:39 dual lockd: failed to monitor server
Oct 16 09:21:39 dual statd: server localhost not responding, timed out
Oct 16 09:21:39 dual lockd: cannot monitor server
Oct 16 09:21:39 dual lockd: failed to monitor server
Oct 16 09:22:09 dual statd: server localhost not responding, timed out
Oct 16 09:22:09 dual lockd: cannot monitor server
Oct 16 09:22:09 dual lockd: failed to monitor server
Oct 16 09:22:39 dual statd: server localhost not responding, timed out
Oct 16 09:22:39 dual lockd: cannot monitor server
Oct 16 09:22:39 dual lockd: failed to monitor server
Oct 16 09:23:10 dual statd: server localhost not responding, timed out
Oct 16 09:23:10 dual lockd: cannot monitor server
Oct 16 09:23:10 dual lockd: failed to monitor server
Oct 16 09:23:41 dual statd: server localhost not responding, timed out
Oct 16 09:23:41 dual lockd: cannot monitor server
Oct 16 09:23:41 dual lockd: failed to monitor server
Oct 16 09:24:12 dual statd: server localhost not responding, timed out
Oct 16 09:24:12 dual lockd: cannot monitor server
Oct 16 09:24:12 dual lockd: failed to monitor server
Oct 16 09:24:42 dual statd: server localhost not responding, timed out
Oct 16 09:24:42 dual lockd: cannot monitor server
Oct 16 09:24:42 dual lockd: failed to monitor server
Oct 16 09:25:12 dual statd: server localhost not responding, timed out
Oct 16 09:25:12 dual lockd: cannot monitor server
Oct 16 09:25:12 dual lockd: failed to monitor server
Oct 16 09:25:16 dual statd: server localhost not responding, timed out
Oct 16 09:25:16 dual lockd: cannot monitor server
Oct 16 09:25:16 dual lockd: failed to monitor server
Oct 16 09:25:42 dual statd: server localhost not responding, timed out
Oct 16 09:25:42 dual lockd: cannot monitor server
Oct 16 09:25:42 dual lockd: failed to monitor server
Oct 16 09:25:46 dual statd: server localhost not responding, timed out
Oct 16 09:25:46 dual lockd: cannot monitor server
Oct 16 09:25:46 dual lockd: failed to monitor server
Oct 16 09:26:16 dual statd: server localhost not responding, timed out
Oct 16 09:26:16 dual lockd: cannot monitor server
Oct 16 09:26:16 dual lockd: failed to monitor server
Oct 16 09:26:46 dual statd: server localhost not responding, timed out
Oct 16 09:26:46 dual lockd: cannot monitor server
Oct 16 09:26:46 dual lockd: failed to monitor server
Oct 16 09:27:16 dual statd: server localhost not responding, timed out
Oct 16 09:27:16 dual lockd: cannot monitor server
Oct 16 09:27:16 dual lockd: failed to monitor server
Oct 16 09:27:16 dual statd: server localhost not responding, timed out
Oct 16 09:27:16 dual lockd: cannot monitor server
Oct 16 09:27:16 dual lockd: failed to monitor server
Oct 16 09:27:46 dual statd: server localhost not responding, timed out
Oct 16 09:27:46 dual lockd: cannot monitor server
Oct 16 09:27:46 dual lockd: failed to monitor server
Oct 16 09:28:16 dual statd: server localhost not responding, timed out
Oct 16 09:28:16 dual lockd: cannot monitor server
Oct 16 09:28:16 dual lockd: failed to monitor server
Oct 16 09:28:26 dual statd: server localhost not responding, timed out
Oct 16 09:28:26 dual lockd: cannot monitor server
Oct 16 09:28:26 dual lockd: failed to monitor server
Oct 16 09:28:26 dual statd: server localhost not responding, timed out
Oct 16 09:28:26 dual lockd: cannot monitor server
Oct 16 09:28:26 dual lockd: failed to monitor server
Oct 16 09:28:27 dual statd: server localhost not responding, timed out
Oct 16 09:28:27 dual lockd: cannot monitor server
Oct 16 09:28:27 dual lockd: failed to monitor server
Oct 16 09:28:27 dual statd: server localhost not responding, timed out
Oct 16 09:28:27 dual lockd: cannot monitor server
Oct 16 09:28:27 dual lockd: failed to monitor server
Oct 16 09:28:46 dual statd: server localhost not responding, timed out
Oct 16 09:28:46 dual lockd: cannot monitor server
Oct 16 09:28:46 dual lockd: failed to monitor server
Oct 16 09:28:57 dual statd: server localhost not responding, timed out
Oct 16 09:28:57 dual lockd: cannot monitor server
Oct 16 09:28:57 dual lockd: failed to monitor server
Oct 16 09:28:57 dual statd: server localhost not responding, timed out
Oct 16 09:28:57 dual lockd: cannot monitor server
Oct 16 09:28:57 dual lockd: failed to monitor server
Oct 16 09:28:57 dual statd: server localhost not responding, timed out
Oct 16 09:28:57 dual lockd: cannot monitor server
Oct 16 09:28:57 dual lockd: failed to monitor server
Oct 16 09:29:16 dual statd: server localhost not responding, timed out
Oct 16 09:29:16 dual lockd: cannot monitor server
Oct 16 09:29:16 dual lockd: failed to monitor server
Oct 16 09:29:17 dual statd: server localhost not responding, timed out
Oct 16 09:29:17 dual lockd: cannot monitor server
Oct 16 09:29:17 dual lockd: failed to monitor server
Oct 16 09:29:46 dual statd: server localhost not responding, timed out
Oct 16 09:29:46 dual lockd: cannot monitor server
Oct 16 09:29:46 dual lockd: failed to monitor server
Oct 16 09:29:47 dual statd: server localhost not responding, timed out
Oct 16 09:29:47 dual lockd: cannot monitor server
Oct 16 09:29:47 dual lockd: failed to monitor server
Oct 16 09:30:03 dual login(pam_unix)[6525]: session closed for user reinhold
Oct 16 09:30:07 dual login(pam_unix)[6700]: session opened for user root by (uid=0)
Oct 16 09:30:07 dual login[6701]: ROOT LOGIN on 'tty2'


Wo kommt sowas her und was macht man am Besten dagegen?

PS: Nochwas ist mir aufgefallen wieso sagt der beispielsweise

...
statd: server localhost not responding ...
^^^^^^^^^

NFS-Server ist doch der Host namens "server" und nicht "localhost".

Danke schonmal!

tomiondrums
16.10.07, 10:11
Das Problem hat sich soeben von selbst gelöst.
Nochmals vielen herzlichen Dank für deinen Hinweis!!


/etc/init.d/nfsmount start
startet den statd und auf einen Schlag sind alle Probleme weg!

Auch praktisch (für alle, die dasselbe Problem haben):

rc-update add nfsmount default

bla!zilla
16.10.07, 10:16
Ja wunderbar. :) Klasse das du deine Lösung hier gepostet hast, machen die Leute leider viel zu selten.