Hallo, Am Sam, 06 Mär 2010, Thomas Moritz schrieb:
Am Samstag, 6. März 2010 20:17:05 schrieb David Haller:
Was spuckt 'hostname' bzw. 'hostname -f' aus?
Du bist wiedermal der Groesste :-) In 'hostname' steht sofort die Aenderung.
Prima. 'hostname -f' sollte übrigens den fqdn ausspucken (sonst ist deine /etc/hosts falsch ;)
Ein echo "$HOSTNAME" behaelt brav den alten Hostnamen! Bug in YaST & Co.?
Nein. Das liegt schlicht und einfach daran, wie die shell arbeitet und was Umgebungsvariablen sind. HOSTNAME wird in /etc/profile gesetzt und exportiert. Und die /etc/profile wird von dieser login-shell dann nicht mehr gelesen. Du mußt also dafür sorgen, daß die /etc/profile erneut gelesen wird, z.B. durch . /etc/profile . ~/.profile . ~/.bashrc oder durch den Start einer neuen login-shell. -dnh -- In fact, it's surprising that any sort of hardware works. When it works, it is just biding its time waiting for a more inconvenient time for it to fail. -- Joe Moore -- To unsubscribe, e-mail: opensuse-programming-de+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-programming-de+help@opensuse.org