Quantcast
Channel: Recent Questions - Stack Overflow
Viewing all articles
Browse latest Browse all 12111

Iam not able to login to bastion server-permission denied error

$
0
0

When I login to bastion server every time, there is initial shell script which will run and records sessions.

  LOG_FILE="`date --date="today" "+%Y-%m-%d_%H-%M-%S"`_`whoami`"  LOG_DIR="/var/log/ssh-bastion/"  echo ""  echo "NOTE: This SSH session will be recorded"  echo "AUDIT KEY: $LOG_FILE"  echo ""  # suffix the log file name with a random string.  SUFFIX=`mktemp -u _XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX`  script -qf --timing=$LOG_DIR$LOG_FILE$SUFFIX.time $LOG_DIR$LOG_FILE$SUFFIX.data --command=/bin/bashelse  echo "This bastion supports interactive sessions only. Do not supply a command"  exit 1fi```Now when I try to login its giving below error```script: cannot open /var/log/ssh-bastion/2024-03-29_06-52-11_username_m8hI1GxwGYd5847vhanBcn9Www1Koq8X.data: Permission denied```It was working well earlier and I have been facing this issue since 2 days. All my directory permissions are same and there is no change in any file/directory permissions.

Viewing all articles
Browse latest Browse all 12111

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>