man bash When bash is invoked as an interactive login shell, or as a non-interactive shell with the --login option, it first reads and executes commands from the file /etc/profile, if that file exists. After reading that file, it looks for ~/.bash_profile, ~/.bash_login, and ~/.profile, in that order, and reads and executes commands from the first one that exists and is readable. The --noprofile option may be used when the shell is started to inhibit this behavior.
When a login shell exits, bash reads and executes commands from the file ~/.bash_logout, if it exists. When an interactive shell that is not a login shell is started, bash reads and executes commands from /etc/bash.bashrc and ~/.bashrc, if these files exist. This may be inhibited by using the --norc option. The --rcfile file option will force bash to read and execute commands from file instead of /etc/bash.bashrc and ~/.bashrc. [EMAIL PROTECTED]:~$ cat .profile # ~/.profile: executed by Bourne-compatible login shells. if [ -f ~/.bashrc ]; then . ~/.bashrc fi #PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/bin/X11 #export PATH mesg n cu mb Holger Rauch wrote: > Hallo, > > ich habe bei einem neu aufgesetzten Testing (Etch) System das Problem, daß > nach einem ssh login die .bash_profile und die .bashrc im HOME-Verzeichnis > eines Benutzers nicht mehr gesourced werden. > > Wenn ich auf diesem neu installierten System von einem user mittels > "su - <user_name>" auf einen anderen user wechsle, werden .bash_profile und > .bashrc wie erwartet gesourced. > > Bei einem System, das ich seit geraumer Zeit von Sarge auf Etch upgedated > habe, gibt es dieses Problem interessanterweise NICHT (zumindest hab ich es > bis jetzt noch nicht bemerkt). > > Meine ersten Verdächtigen waren die SSH-Konfiguration (server- und > client-seitig) bzw. die PAM-Konfiguration. Allerdings konnte ich da erstmal > nix feststellen. In den README.Debian files zu den PAM packages konnte ich > ebenfalls nix finden. > > Offensichtliche Fragen: > > - Woran liegt es, daß nach ssh logins auf einem neu hochgezogenen > Etch-/Testing-System die .bash_profile/.bashrc im HOME-Verzeichnis eines > Benutzers nicht mehr gesourced werden? > > - Was muß man an welchen config files ändern, um das "alte" Verhalten > (Berücksichtigung von benutzer-spezifischen .bash_profile/.bashrc files) > wieder herzustellen? > > Vielen Dank im Voraus für die Info! > > Gruß, > > Holger > -- > GPG key: 0x965D2902 > GPG key fingerprint: 3FE8 7472 2637 2993 6BD7 015E 6E25 6D5A 965D 2902 -- Haeufig gestellte Fragen und Antworten (FAQ): http://www.de.debian.org/debian-user-german-FAQ/ Zum AUSTRAGEN schicken Sie eine Mail an [EMAIL PROTECTED] mit dem Subject "unsubscribe". Probleme? Mail an [EMAIL PROTECTED] (engl)

