我在USB上有一个可启动的CloneZilla。它非常适合使用syslinux引导的系统。这是syslinux.cfg
中的菜单项以及其功能的简短说明(请注意,我使用&表示这是同一行,为了便于阅读,我将其分成多行):
label Clone Default Image
#MENU DEFAULT
MENU LABEL Clone from \\bilbo
kernel /live/vmlinuz
append initrd=/live/initrd.img boot=live union=overlay config quiet noswap
& noeject nosplash username=user hostname=yakkety components edd=on nomodeset
& noprompt nolocales keyboard-layouts=sv locales=sv_SE.UTF-8
& ocs_live_run="ocs-sr --batch -g auto -e1 auto -e2 -r -j2
& -p poweroff restoredisk windows-10-base-clone sda" ocs_live_extra_param=""
& ocs_live_batch=no vga=791 ip= nosplash i915.blacklist=yes radeonhd.blacklist=yes
& nouveau.blacklist=yes vmwgfx.blacklist=yes
& ocs_repository="smb://administrator:**********@192.168.10.41/common/utveckling/clone"
& {lots of ocs_preruns to setup dhcp on one of two possible eth-interfaces}
它将设置一个eth-interface以使用dhcp。然后,它尝试安装samba共享,如ocs_repository =“ user:pass @ path”所示。之后,它应该运行ocs_live_run =“ cmd”条目,该条目执行从samba位置到已引导设备的主磁盘的克隆。
这是我尝试创建等效的
grub.cfg
条目的尝试:menuentry "Clone from \\\\bilbo"{
search --set -f /live/vmlinuz
linux /live/vmlinuz boot=live union=overlay config quiet noswap
& noeject nosplash username=user hostname=yakkety components edd=on nomodeset
& noprompt nolocales keyboard-layouts=sv locales=sv_SE.UTF-8
& ocs_live_run="ocs-sr --batch -g auto -e1 auto -e2 -r -j2
& -p poweroff restoredisk windows-10-base-clone sda" ocs_live_extra_param=""
& ocs_live_batch=no vga=791 ip= nosplash i915.blacklist=yes radeonhd.blacklist=yes
& nouveau.blacklist=yes vmwgfx.blacklist=yes
& ocs_repository="smb://administrator:**********@192.168.10.41/common/utveckling/clone"
& {same preruns, it seems to work well}
initrd /live/initrd.img
}
无论出于什么原因,grub都会失败。似乎尝试做相同的事情,但是我敢打赌,安装samba-location会有问题(我可以手动安装)。
它停止并显示错误消息“ / home / partimag / windows-10-base-clone”,如果将提供的samba位置安装到/ home / partimag /,则该错误消息当然应该存在。
有什么建议么?
最佳答案
我遇到了一个非常相似的问题,我注意到通过添加更长的“ sleep”调用,mount
命令会调用帮助文件进行挂载,因此我知道存在语法错误,但是相同的语法在iso /中有效syslinux.cfg以及ocs_live_run
失败后的提示。
我发现ocs_prerun="Mount..."
必须在不使用\
转义“的情况下运行。
从而:
OCS_PRERUN5=\"Mount -o user=,pass= //host/path/ /home/partimag\"
我希望如果您仍在进行此工作,那么它也对您有用。
关于linux - CloneZilla USB,无人值守的syslinux,需要转换为grub等效,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/42999450/