• <output id="aynwq"><form id="aynwq"><code id="aynwq"></code></form></output>

    <mark id="aynwq"><option id="aynwq"></option></mark>
  • <mark id="aynwq"><option id="aynwq"></option></mark><label id="aynwq"><dl id="aynwq"></dl></label>
  • 學(xué)習(xí)啦 > 學(xué)習(xí)電腦 > 操作系統(tǒng) > Linux教程 > linux系統(tǒng)怎么封裝

    linux系統(tǒng)怎么封裝

    時(shí)間: 春健736 分享

    linux系統(tǒng)怎么封裝

      window xp通過相關(guān)的工具軟件,進(jìn)行封裝后,可以GHOST到其他計(jì)算機(jī)上,那LINUX系統(tǒng)可否也實(shí)現(xiàn)。如何操作?下面大家與學(xué)習(xí)啦小編一起來學(xué)習(xí)一下吧。

      linux系統(tǒng)怎么封裝

      第一步生成ks.cfg文件

      我這里使用的遠(yuǎn)程連接工具是Xmanager Enterprise 4,可以支持在當(dāng)前系統(tǒng)上打開遠(yuǎn)程主機(jī)的圖形軟件界面。

      1、首先確認(rèn)kickstart是否安裝,沒有安裝的話使用yum進(jìn)行安裝

    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    #檢查 kickstart是否安裝
    [root@lovelace ~]# rpm -qa | grep kickstart
    system-config-kickstart-2.6.19.9-2.el5
    pykickstart-0.43.9-1.el5
    #使用yum安裝 kickstart
    [root@lovelace ~]# yum install system-config-kickstart -y
    Loaded plugins: katello, security
    Repository rhel-debuginfo is listed more than once in the configuration
    Unable to read consumer identity
    Setting up Install Process
    Package system-config-kickstart-2.6.19.9-2.el5.noarch already installed and latest version
    Nothing to do

      2、啟動(dòng)Xmanager - Passive服務(wù),然后在終端上輸入命令system-config-kickstart &

    linux系統(tǒng)怎么封裝

      如果執(zhí)行上面的命令彈出錯(cuò)誤,請(qǐng)?jiān)诮K端輸入以下兩條命令

    linux系統(tǒng)怎么封裝

      3、再次進(jìn)行測(cè)試,如果還不成功,請(qǐng)查看服務(wù)是否開啟,上面兩條命令執(zhí)行是否成功

      注:這里為了方便大家進(jìn)行配置,直接在現(xiàn)有系統(tǒng)的基礎(chǔ)上進(jìn)行編輯。

      4、在彈出的圖形界面點(diǎn)擊文件---->打開文件---->root目錄下---->anaconda-ks.cfg文件---->確定。

    linux系統(tǒng)怎么封裝

      5、開始我們的ks.cfg文件編輯過程(選擇語言,鍵盤類型,時(shí)區(qū),設(shè)置根口令,安裝后是否重啟引導(dǎo)系統(tǒng),在文本模式下進(jìn)行安裝)

    linux系統(tǒng)怎么封裝

      6、安裝方法的選擇(這里我們是對(duì)磁盤進(jìn)行全新封裝的,選擇執(zhí)行新安裝,安裝方法為光盤驅(qū)動(dòng)器)

    linux系統(tǒng)怎么封裝

      7、引導(dǎo)裝載程序選項(xiàng),(給內(nèi)核傳遞參數(shù)rhgb quiet ,其他默認(rèn)即可)

    linux系統(tǒng)怎么封裝

      8、分區(qū)信息設(shè)置,這里我們新建三個(gè)分區(qū)(/分區(qū):5G, /boot:200M, swap分區(qū):1G)

    linux系統(tǒng)怎么封裝

      9、網(wǎng)絡(luò)配置(這里選擇添加eth0網(wǎng)卡,IP為dhcp自動(dòng)分配)

    linux系統(tǒng)怎么封裝

      10、驗(yàn)證方式默認(rèn)即可

    linux系統(tǒng)怎么封裝

      11、防火墻配置(這里選擇禁用)

    linux系統(tǒng)怎么封裝

      12、顯示配置(這里我們選擇安裝X界面,色彩深度調(diào)整為16,RHEL上默認(rèn)安裝的是gnome)

    linux系統(tǒng)怎么封裝

      13、軟件包安裝選擇(按需自定義選擇)

    linux系統(tǒng)怎么封裝

      14、預(yù)安裝腳本(按需進(jìn)行設(shè)置)

    linux系統(tǒng)怎么封裝

      15、安裝后腳本(按需進(jìn)行設(shè)置)

    linux系統(tǒng)怎么封裝

      14、保存配置好的文件(可自定義存放路徑,這里我們存放到/home目錄下)

    linux系統(tǒng)怎么封裝

      查看生成的ks.cfg配置文件

    1
    2
    3
    4
    #驗(yàn)證ks.cfg文件是否存在
    [root@lovelace home]# pwd;ll ks.cfg
    /home
    -rw-r--r-- 1 root root 1649 05-27 04:20 ks.cfg

      查看ks.cfg文件 具體參數(shù)請(qǐng)查看kickstart文檔

    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    32
    33
    34
    35
    36
    37
    38
    39
    40
    41
    42
    43
    44
    45
    46
    47
    48
    49
    50
    51
    52
    53
    54
    55
    56
    57
    58
    59
    60
    61
    62
    63
    64
    65
    66
    67
    68
    69
    70
    71
    72
    73
    74
    75
    [root@lovelace home]# cat ks.cfg
    #platform=x86, AMD64, 或 Intel EM64T
    # System authorization information
    auth  --useshadow  --enablemd5
    # System bootloader configuration
    bootloader --append="rhgb quiet" --location=mbr --driveorder=sda
    # Partition clearing information
    clearpart --none
    # Use text mode install
    text
    # Firewall configuration
    firewall --disabled
    # Run the Setup Agent on first boot
    firstboot --disable
    key --skip
    # System keyboard
    keyboard us
    # System language
    lang en_US
    # Installation logging level
    logging --level=info
    # Use CDROM installation media
    cdrom
    # Network information
    network --bootproto=dhcp --device=eth0 --onboot=on
    # Reboot after installation
    reboot
    #Root password
    rootpw --iscrypted $1$/3RmiuX/$ZqpoSJEqBLYu93wL6a60R1
    # SELinux configuration
    selinux --enforcing
    # System timezone
    timezone --isUtc Asia/Shanghai
    # Install OS instead of upgrade
    install
    # X Window System configuration information
    xconfig  --defaultdesktop=GNOME --depth=8 --resolution=640x480
    # Disk partitioning information
    part / --bytes-per-inode=4096 --fstype="ext3" --size=6000
    part /boot --bytes-per-inode=4096 --fstype="ext3" --size=200
    part swap --bytes-per-inode=4096 --fstype="swap" --size=1024
    %packages
    @base
    @development-libs
    @core
    @development-tools
    @sound-and-video
    @x-software-development
    @gnome-desktop
    @base-x
    @printing
    @gnome-software-development
    @admin-tools
    @legacy-software-support
    @editors
    @text-internet
    @dialup
    @graphics
    @office
    @java
    @graphical-internet
    @games
    kexec-tools
    iscsi-initiator-utils
    fipscheck
    device-mapper-multipath
    sgpio
    python-dmidecode
    imake
    emacs
    libsane-hpaio
    mesa-libGLU-devel
    xorg-x11-utils
    xorg-x11-server-Xnest
    xorg-x11-server-Xvfb

      第二步:修改isolinux.cfg配置文件(有多種方向進(jìn)行選擇,這里不再演示)

      修改后內(nèi)容為(Note:網(wǎng)上好多關(guān)于這個(gè)配置文件各不相同,只要能夠?qū)嶒?yàn)成功就行)

    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    [root@lovelace home]# cat isolinux.cfg
    default ks
    prompt 1
    timeout 60
    display boot.msg
    F1 boot.msg
    F2 options.msg
    F3 general.msg
    F4 param.msg
    F5 rescue.msg
    label linux
    kernel vmlinuz
    append initrd=initrd.img
    label text
    kernel vmlinuz
    append initrd=initrd.img text
    label ks
    kernel vmlinuz
    append ks=cdrom:/ks.cfg initrd=initrd.img
    label local
    localboot 1
    label memtest86
    kernel memtest
    append -

      第三步:重新封裝iso鏡像文件(win下操作)

      1、打開原版iso鏡像文件(刪除自動(dòng)的isolinux.cfg文件,然后把我們重新編輯過的文件添加進(jìn)去)

    linux系統(tǒng)怎么封裝

      2、添加我們制作的ks.cfg文件到光盤根目錄下,然后進(jìn)行iso文件生成即可

    linux系統(tǒng)怎么封裝

      第四步:測(cè)試安裝(這里截兩張圖驗(yàn)證下)

    linux系統(tǒng)怎么封裝
    linux系統(tǒng)怎么封裝

      后記:其實(shí)做這個(gè)也沒有多大意義,因?yàn)樯a(chǎn)環(huán)境中都是批量部署的,這里希望大家能夠了解下關(guān)于ks.cfg文件的編輯方法,如果你很熟悉的話,也可以脫離圖形編輯,直接命令行進(jìn)行設(shè)置。

       看過“ linux系統(tǒng)怎么封裝 ”的人還看了:

    1.Linux系統(tǒng)常用命令合集

    2.linux系統(tǒng)怎么安裝

    3.如何把Linux操作系統(tǒng)變成中文語言

    4.LINUX操作系統(tǒng)如何安裝圖形界面

    5.老舊電腦怎么安裝開源的Linux系統(tǒng)

    655097 主站蜘蛛池模板: 农村妇女色又黄一级毛片不卡| 国产女主播一区| 久久亚洲精品中文字幕| 精品久久久久久久中文字幕 | 日本最新免费二区| 免费极品av一视觉盛宴| 亚洲香蕉久久一区二区| 成人A级视频在线播放| 亚洲国产第一区| 美女内射毛片在线看3D| 国产综合久久久久鬼色| 中文字幕日韩高清版毛片| 欧美粗大猛烈老熟妇| 国产一级做a爱片久久毛片a| 97国产在线视频公开免费| 日日干夜夜操视频| 亚洲日本va在线观看| 老司机午夜精品视频在线观看免费| 国产视频2021| 中国老人倣爱视频| 欧美91精品久久久久网免费| 全免费a级毛片免费**视频| 国产三级小视频在线观看| 女人洗澡一级毛片一级毛片| 久久国产精品二国产精品| 波多野结衣一二三区| 国产gav成人免费播放视频| 18禁男女爽爽爽午夜网站免费| 成人三级精品视频在线观看| 亚洲av永久综合在线观看尤物| 秋霞鲁丝片无码av| 国产在线无码视频一区二区三区 | 无码囯产精品一区二区免费| 亚洲欧美国产免费综合视频| 经典国产乱子伦精品视频| 国产疯狂露脸对白| ass日本乱妇bbw| 成年人电影在线播放| 亚欧洲精品bb| 沈婷婷小雷第三次| 午夜爽爽爽男女免费观看hd|