ssgconfig ユーザーを使用して API Gateway にログインすると、アカウント有効期限切れのエラーが表示されます。
Your account has expired; please contact your system administrator
User account has expired
ssgconfig ユーザーアカウントの有効期限が切れています。
コマンド実行結果:
# chage -l ssgconfig
Last password change : Ago 16, 2022
Password expires : May 21, 2049
Password inactive : never
Account expires : Ago 08 , 2022
Minimum number of days between password change : 1
Maximum number of days between password change : 9999
Number of days of warning before password expires : 7
以下の手順を実行して、アカウントの有効期限を無期限に設定します。
1. API Gateway の Linux サーバーを再起動します。
2. grub メニューをロードするときに「e」を入力します。
3. 下矢印キーで「linux16」という単語を検索してから、右矢印キーを使用して UTF-8 まで移動します。
4. スペースを追加して、以下を書き込みます。
audit=1 init=/bin/bash
5. CTRL-x を押して保存し、Linux ブートを再起動します。
6. 再起動の代わりに「bash-4.2#」プロンプトが表示されます。
7. 次のコマンドを使用してルート ファイル システムをマウントします。
mount -o remount,rw /
8. 以下を実行します。
chage -M 99999 -E -1 ssgconfig
注: -E -1 (マイナス 1) は、“Account expires” (アカウントの有効期限)を「無期限」に設定します。これは検証のみを目的としており、実運用環境では使用しないでください。
9. 以下を実行します。
chage -l ssgconfig
次のような内容が表示されます:
bash-4.2# chage -l ssgconfig
Last password change : Jan 04, 2022
Password expires : May 21, 2049
Password inactive : never
Account expires : never
Minimum number of days between password change : 1
Maximum number of days between password change : 99999
Number of days of warning before password expires : 7
bash-4.2# chage -l root
root も有効期限が切れでないことを確認します。有効期限切れの場合は、root に対して同様なコマンドを実行します ( chage -M 99999 -E -1 root)。
9. exit と入力します。
bash-4.2# exit
Enter キーを押して起動/再起動を許可します。
10. ssgconfig パスワードを使用して API Gateway にアクセスします。