juniper m7のパスワードリカバリー | 技術ブログ

juniper m7のパスワードリカバリー

ネットワーク部1年の活動記録です

開催日時

2025年10月24日(金)17:00〜18:00

参加者

ConvivialNet ネットワーク部メンバー3名

活動内容

パスワード不明のルータ(juniper m7)を使える状態にする試み

【1】

Hit [Enter] to boot immediately, or space bar for command prompt.
Booting [kernel] in 9 seconds…

が表示されたタイミングでenterを目押しする(意外と難しい!!)

【2】boot -s と入力し、システムをシングルユーザー モードで起動

【3】

Enter full pathname of shell or 'recovery' for root password recovery or RETURN for /bin/sh: recovery

で recovery と入力

【4】FreeBSDベースのオペレーティングシステム(JUNOS)が起動時にファイルシステムの整合性チェック(fsck)を行った際、/var パーティションに破損が見つかり、自動修復に失敗したことがわかりました。

error: filesystem consistency checks (fsck -p -y) failed

An emergency shell can be started to repair any damage and
perform the required operation before exiting and allowing
this script to continue operation.

continue, shell, abort, retry, or reboot ? 

shell を入力して緊急シェルに入ります。

【5】fsck -y /dev/ad1s1f を入力し、手動で fsck を実行。完了したら exit でシェルを抜けます。

【6】

root> configure
...
Entering configuration mode [edit]
root# set system root-authentication plain-text-password
New password:
Retype new password:

成果

無事にパスワードを再設定しました。今後このルータも活用していきたいですね!(^^)c

感想

  • 菅原 「白波が目押し頑張ってくれました👏!」
  • 西村k 「目押しに圧巻」
  • 白波 「目押し楽しかった!」

この記事の著者

菅原

菅原

25年度ネットワーク部1年です。