官方链接:
http://gparted.sourceforge.net/index.php
http://gparted.sourceforge.net/download.php
http://gparted.sourceforge.net/livepxe.php
参考文档:
http://www.debian-administration.org/article/478/Setting_up_a_server_for_PXE_network_bootinghttp://drbl.sourceforge.net
http://clonezilla.nchc.org.tw/clonezilla-live/livepxe.php
http://clonezilla.nchc.org.tw/clonezilla-live/doc/fine-print.php?path=./99_Misc/00_live-initramfs-manual.doc#00_live-initramfs-manual.doc
一. 简介:
GParted is a free partition editor for graphically managing your
disk partitions.
With GParted you can resize, copy, and move partitions without data
loss, enabling you to:
- Grow or shrink your C: drive
- Create space for new operating systems
- Attempt data rescue from lost partitions
![pxe引导gparted <wbr>live万能分区 GParted Main screen](http://simg.sinajs.cn/blog7style/images/common/sg_trans.gif)
Discover More
- Learn why partition your disk device.
- Explore the documentation and FAQ.
- Get help with disk partitioning.
- View screenshots of GParted in action.
Features
- Perform actions with partitions such as:
- create or delete
- resize or move
- check
- label
- set new UUID
- copy and paste
- Manipulate file systems such as:
- btrfs
- ext2 / ext3 / ext4
- fat16 / fat32
- hfs / hfs+
- linux-swap
- lvm2 pv
- nilfs2
- ntfs
- reiserfs / reiser4
- ufs
- xfs
Requirements
GParted can be used on x86 and x86-64 based computers running Linux, Windows, or Mac OS X by booting from media containing GParted Live. A minimum of 160 MB of RAM is needed to use all of the features of the GParted application.
Free Software
GParted is free
software.
You have the freedom to run, copy, distribute, study, change, and
improve GParted.
You do not have to pay money to use GParted.
GParted is distributed under the GNU General
Public License version 2 or (at your option) any later
version.
二. 搭建PXE环境:
gparted live cd是基于debian-live,所以,syslinux参数和红帽的有些区别,具体的可以参看文章开头的参考文档。
有兴趣的朋友可以参考在下的拙篇,这里就不再细述,欢迎大家批评指正
CenOS6 nginx+pxe+tftpd+samba/nfs+dhcpd 无盘安装windows & linux
Ubuntu12.04 nginx+pxe+tftpd+samba/nfs+dhcpd 无盘安装windows & linux
以下是gparted live官方的帮助文档。
GParted Live on PXE Server
Besides GParted Live CD and Live USB, we can put the GParted Live image on a PXE server so that a client can boot via the network to use GParted. The steps to do this are as follows:
- Set up a PXE server. You might refer to documentation, such as
setting up a server for PXE network booting, or
DRBL
(Diskless Remote Boot in Linux) to assist you.
In these steps we assume the pxelinux config file is /tftpboot/nbi_img/pxelinux.cfg/default, and the image files are in /tftpboot/nbi_img/. - Set up an http service on the PXE server.
- Download GParted live zip file. You have to use 0.3.7-2 or later because network drivers are only included after that.
- Unzip all the files in a temp dir /tmp/gparted/. You can do
this with a command such as:
mkdir -p /tmp/gparted; unzip gparted-live-*.zip -d /tmp/gparted/
NOTE: Replace gparted-live-*.zip with the file name you just downloaded. - Copy the necessary boot files (vmlinuz and initrd.img) to
/tftpboot/nbi_img/. For example:
cp /tmp/gparted/live/{vmlinuz,initrd.img} /tftpboot/nbi_img/
- Copy /tmp/gparted/live/filesystem.squashfs to your http server.
For example:
cp /tmp/gparted/live/filesystem.squashfs /var/www/
- Edit your PXE config file
/tftpboot/nbi_img/pxelinux.cfg/default, and append the
following:
label GParted Live
MENU LABEL GParted Live kernel vmlinuz append initrd=initrd.img boot=live config union=aufs noswap noprompt vga=788 fetch=http://$webserverIP/filesystem.squashfs - NOTE1: Replace $webserverIP with the IP address
of your http server.
NOTE2: Remember to check the boot parameters in syslinux/syslinux.cfg from the zip file. You should replace the above listed parameters with these more recent ones because these newer boot parameters might be different. For example the vmlinuz path might be different.
NOTE3: Do not use the parameter "ip=frommedia" in your PXE config file.
For more information about pxelinux, refer to the following article on PXELinux.
这里以GParted live 0.19.1-4为例:gparted-live-0.19.1-4-amd64.iso
New in this release:
-
The underlying GNU/Linux operating system was upgraded. This release is based on the Debian Sid repository (as of 2014/Aug/29).
-
New GParted release 0.19.1.
-
Linux kernel was updated to 3.14.15-2.
-
Program MC_HxEd was removed from GParted live because it's not maintained anymore.
-
Program zenity instead of gdialog is used in gl-shutdown-menu.
三. 定义gparted
pxe菜单:
mount -o loop
/mnt/ISO/gparted-live-0.19.1-4-amd64.iso
mkdir /var/lib/tftpboot/gparted
cp -av /mnt/iso/live /var/lib/tftpboot/gparted
cp -av /mnt/iso/live/filesystem.squashfs
/var/www/pub/ftp/gparted
cp -av /mnt/iso/syslinux/syslinux.cfg /var/lib/tftpboot/gparted/default
以下是我个人的gparted pxe菜单/var/lib/tftpboot/gparted/default,把iso中的syslinux.cfg另存为default再加以修改即可,仅供参考。
注:这里最重要的就是filesystem.squashfs这个文件,fetch支持tftp,ftp,http这几种模式,我这里选用的是http模式,所以看的到是fetch=http://192.168.8.254/ftp/gparted/filesystem.squashfs
default
/gparted/vesamenu.c32
#prompt 1
timeout 600
display /gparted/boot.msg
menu background /gparted/Gsplash.png
menu title Gnome Partition Editor
menu color border 0 #ffffffff #00000000
menu color sel 7 #ffffffff #ff000000
menu color title 0 #ffffffff #00000000
menu color tabmsg 0 #ffffffff #00000000
menu color unsel 0 #ffffffff #00000000
menu color hotsel 0 #ff000000 #ffffffff
menu color hotkey 7 #ffffffff #ff000000
menu color scrollbar 0 #ffffffff #00000000
# MENU MASTER PASSWD
say
**********************************************************************
say GParted.
say Gnome Partition Editor.
say http://gparted.org
say THIS SOFTWARE COMES WITH ABSOLUTELY NO WARRANTY! USE AT YOUR
OWN RISK!
say
**********************************************************************
# Allow client to edit the parameters
ALLOWOPTIONS 1
# simple menu title
MENU TITLE http://gparted.org
# Since no network setting in the squashfs image, therefore if ip=,
the network is disabled. That's what we want.
label GParted Live (To RAM)
label GParted Live
MENU BEGIN ^Other modes of GParted Live
label GParted Live KMS
label GParted Live without framebuffer
label GParted Live failsafe mode
MENU END
label local
# Note! *.bin is specially purpose for syslinux,
# Do NOT use memtest.bin, use memtest instead of memtest.bin
label memtest
四. 效果图:
![pxe引导gparted <wbr>live万能分区 pxe引导gparted <wbr>live万能分区](http://simg.sinajs.cn/blog7style/images/common/sg_trans.gif)
![pxe引导gparted <wbr>live万能分区 pxe引导gparted <wbr>live万能分区](http://simg.sinajs.cn/blog7style/images/common/sg_trans.gif)
![pxe引导gparted <wbr>live万能分区 pxe引导gparted <wbr>live万能分区](http://simg.sinajs.cn/blog7style/images/common/sg_trans.gif)
键盘映射,一般标准的美式键盘直接选择
![pxe引导gparted <wbr>live万能分区 pxe引导gparted <wbr>live万能分区](http://simg.sinajs.cn/blog7style/images/common/sg_trans.gif)
系统语言,很遗憾目前还没有中文支持,中国的开源自由事业还有很长的路要走。默认 [33] 美式英语
![pxe引导gparted <wbr>live万能分区 pxe引导gparted <wbr>live万能分区](http://simg.sinajs.cn/blog7style/images/common/sg_trans.gif)
模式选择,默认是 [0] X 环境,可选的[1] 自定义 X
![pxe引导gparted <wbr>live万能分区 pxe引导gparted <wbr>live万能分区](http://simg.sinajs.cn/blog7style/images/common/sg_trans.gif)