Pythontr

husonet | Tarih: 17.04.2024

root otomatik logout bash_profile,bashrc

Selamun Aleykum,

Eklenecek satır /root/.bashrc yada /root/bash_profile dosyalarında birine eklemeniz yeterlidir.
# timeout logout işlemi için 1200 saniye
export TMOUT=1200

Gerekli olduğunda sadece belirli userlar için bunun geçerli olması için kişilerin profile dosyalarına sistem genelinde tüm kullanıcılara geçerli olması için ” /etc/profile” dosyasına yazabilirsiniz.

Örnek bash_profile dosyam

vim /root/.bash_profile
#############################################################################

export PS1='\[\]\u\[\]@\[\]\h \[\]\w \[\]\$ \[\]'
umask 022

#############################################################################

eval "`dircolors`"

#############################################################################

alias ls='ls $LS_OPTIONS'
alias ll='ls $LS_OPTIONS -l'
alias l='ls $LS_OPTIONS -lA'
alias ..='cd ..'
alias ...='cd ../..'
alias s='ssh -l root'

#############################################################################

export EDITOR="vim"

export HISTFILESIZE=99999999
export HISTSIZE=99999999
export HISTCONTROL="ignoreboth"

export LS_OPTIONS='--color=auto -h'

#############################################################################

# timeout logout işlemi için 1200 saniye
export TMOUT=1200