sun OBP命令总结(精简)
Password: (password is not echoed as it is typed)
Changing the Power-on Banner 设定机器刚刚加电时的banner信息,感觉出了最基本的,其他用处不大。
可用的设置banner的参数: • oem-banner • oem-banner? • oem-logo • oem-logo?
ok setenv oem-banner Hello World ok setenv oem-banner? true ok banner Hello World
输入输出控制 可用的定义控制台的参数: • input-device • output-device • screen-#columns • screen-#rows 下次重启才会生效
默认情况下 input-device是keyboard,output-device是screen.
要讲默认的输入设备改为ttya: ok setenv input-device ttya
假如输入设备是keyboard,输出设备为screen,而设备并没有连接的话系统在下次启动的时候会使用ttya做
为输入输出设备.
example设定ttya做为默认的输入设备: ok setenv input-device ttya
• screen-#columns 设定屏幕列 • screen-#rows 设定行
setenv的使用范例: 设定默认启动设备 ok setenv boot-device net 设置最大化自检 ok setenv diag-switch? True 取消最大化自检 ok setenv diag-switch? false
使用 nvramrc 在nvram中编辑一个脚本在系统启动时执行,这个报存在NVRAM中
通常是为了某些设备驱动定义某些参数使用,或者为某些可能必须在系统加载之前需要执行的操作所准备
。 定义的脚本在什么时候执行呢? 下面是OBP启动的顺序: • 加电自检 (POST) • 执行系统初始化 • 执行nvramrc定义的脚本 (if use-nvramrc? is true) • 执行 probe-all (evaluate FCode) • Execute install-console • 显示banner • Execute secondary diagnostics • 启动操作系统 (if auto-boot? is true)
需要注意的某些命令可能需要在执行了 probe-all之后才能够运行,也就是说我们要充分考虑我们执行的
命令本身运行所需要的环境。
It is sometimes desirable to modify the sequence probe-all installconsole banner. For example, commands that modify the characteristics of plug-in display devices may need to be executed after the plug-in devices have been probed,
but before the console device has been selected. Such commands would need to be executed between probe-all and install-console. Commands that display output on the console would need to be placed after install-console or banner. This is accomplished by creating a custom script which contains either banner or suppress-banner since the sequence probe-all install-console banner is not executed if either banner or suppress-banner is executed from the script. This allows the use of probe-all, install-console and banner inside the script, possibly interspersed with other commands, without having those commands re-executed after the script finishes.
在脚本中可以使用大部分的OBP的命令,但是也有例外 下面的命令不能在脚本中使用: • boot • go • nvedit • password • reset-all • setenv security-mode
本新闻共 6页,当前在第 5页 1 2 3 4 5 6 |