pnetlabv6 Bare Metal do PnetLab(裸机安装|物理机安装)

裸机安装系统的运行速度直的直的比虚拟机运行快多了,所以决定自己整下裸机安装pnetlab.

一台不到一千块的x99双路主机就可以跑的非常流畅,自己上闲鱼或淘宝找找。

Download do Ubuntu Server 20.04.6 LTS(新手建议使用桌面版)

http://mirrors.163.com/ubuntu-releases/20.04.6/ubuntu-20.04.6-desktop-amd64.iso

注意安装完系统需要安装系统软件包更新并重启,所有脚本都在root下运行

sudo -i
apt update -y
apt install openssh-server curl wget -y
apt upgrade -y
reboot

Install PNETLAB

脚本是根据https://drive.labhub.eu.org上的离线包安装脚本修改

wget http://183.56.241.252:82/offline-pnetlab-v6.zip
unzip offline-pnetlab-v6.zip

安装

安装完pnetlab重启,在命令行界面登录root用户完成初始化。

镜像上传。

通过百度网盘分享的文件:Pnet.ova,大小:32.77G

链接:https://pan.baidu.com/s/1nSBXlaU7CLDcthqKm6oOyQ?pwd=pnet

提取码:pnet

把上面镜像从vmware导入,登录这个虚拟机运行下面指令复制

scp /opt/unetlab/*  裸机ip:/opt/unetlab/

Install ishare2(这个镜像工具没有用,经常下载不了,略过吧)

wget -O /usr/sbin/ishare2 https://raw.githubusercontent.com/ishare2-org/ishare2-cli/main/ishare2
chmod +x /usr/sbin/ishare2
ishare2

如果ishare2异常需要重置ishare2

cd /opt
rm ishare2/ -rf

ishare2使用帮助

root@pnetlab:~# ishare2 help
Syntax

ishare2 [action] [param1] [param2] [--overwrite]

action:
    search      : Search for images by type
    pull        : Download an image by type and number
    installed   : Show installed images on server
    labs        : Show labs on server and download images for those labs
    mylabs      : Same as labs command but using a customized path to labs
    relicense   : Generate a new iourc license for bin images
    upgrade     : Retrieves a menu that allows users to upgrade ishare2 and PNETLab VM
    changelog   : Show the latest changes made to ishare2
    gui         : Web app to use ishare2 in browser
    test        : Test internet connectivity to required sites (Github, Google Sheets)
    help        : Show useful information

param1:
    type = all, bin, qemu, dynamips, docker or name

param2:
    number = This number can be obtained using ishare2 search <type>

--overwrite:
    Used to overwrite an existing image if it already exists on your system.

Examples:

- ishare2 search <type>
    - ishare2 search all
    - ishare2 search bin
    - ishare2 search qemu
    - ishare2 search dynamips
    - ishare2 search <name>
        Examples:
            - ishare2 search vios
            - ishare2 search win-
            - ishare2 search winserver
            - ishare2 search kali
            - ishare2 search mikro
            - ishare2 search forti
            - ishare2 search nxos
            - ishare2 search vmx
            - ishare2 search esxi
            - ishare2 search palo
            - ishare2 search Licensed
            - More <name> options using ishare2 search all

- ishare2 pull bin <number> [--overwrite]
- ishare2 pull qemu <number> [--overwrite]
- ishare2 pull dynamips <number> [--overwrite]

- ishare2 pull bin all
- ishare2 pull qemu all (Not available for qemu type due to its large size)
- ishare2 pull dynamips all

- ishare2 installed all
- ishare2 installed bin
- ishare2 installed qemu
- ishare2 installed dynamips
- ishare2 installed docker

- ishare2 labs
- ishare2 labs <number>
- ishare2 labs all

- ishare2 mylabs <path>
- ishare2 mylabs <path> <number>
- ishare2 mylabs <path> all

- ishare2 gui install
- ishare2 gui start
- ishare2 gui stop
- ishare2 gui restart

- ishare2 relicense
- ishare2 upgrade
- ishare2 changelog
- ishare2 test
- ishare2 config
- ishare2 help

ishare2: 3.5.8-main Up to date
ishare2 Channel: main
PNETLab v6.0.0-100 is installed.

使用ishare2拉镜像。

root@pnetlab:~# ishare2 pull bin all
[+] Pulling all IOL images...
[?] Are you sure you want to pull all IOL images? (y/n): y
[+] Pulling image 1/22...
[!] IMAGE INFO

可能出现的问题

1、如果重启出现卡住不动,如提示“switching to amdgpu from efi vga” 或“loading initial ramdisk” 可重启机器在启动菜单修修启动选项添加“nomodeset”参数,怎么修改自己百度或kimi问一下就有了。

2、安装时出现拉不了docker镜像

rror response from daemon: Get "https://registry-1.docker.io/v2/": dial tcp 162.125.32.5:443: i/o timeout

这个要魔法或机票才能解决,目前国内多个docker镜像测试都已经不能使用。

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值