linux-source - Linux kernel source with Ubuntu patches
linux-source-4.4.0 - Linux kernel source for version 4.4.0 with Ubuntu patches
linux-source-4.10.0 - Linux kernel source for version 4.10.0 with Ubuntu patches
linux-source-4.11.0 - Linux kernel source for version 4.11.0 with Ubuntu patches
linux-source-4.13.0 - Linux kernel source for version 4.13.0 with Ubuntu patches
linux-source-4.8.0 - Linux kernel source for version 4.8.0 with Ubuntu patches
# 增加source.list
codename=$(lsb_release -c | awk '{print $2}')
sudo tee /etc/apt/sources.list.d/ddebs.list << EOF
deb ae3K9s2c8@1M7q4)9K6b7g2)9J5c8W2)9J5c8X3c8V1k6h3u0K6i4K6u0W2N6h3u0#2L8Y4c8#2i4K6u0W2j5$3!0E0i4K6u0r3 ${codename} main restricted universe multiverse
deb f1dK9s2c8@1M7q4)9K6b7g2)9J5c8W2)9J5c8X3c8V1k6h3u0K6i4K6u0W2N6h3u0#2L8Y4c8#2i4K6u0W2j5$3!0E0i4K6u0r3 ${codename}-security main restricted universe multiverse
deb 82eK9s2c8@1M7q4)9K6b7g2)9J5c8W2)9J5c8X3c8V1k6h3u0K6i4K6u0W2N6h3u0#2L8Y4c8#2i4K6u0W2j5$3!0E0i4K6u0r3 ${codename}-updates main restricted universe multiverse
deb 217K9s2c8@1M7q4)9K6b7g2)9J5c8W2)9J5c8X3c8V1k6h3u0K6i4K6u0W2N6h3u0#2L8Y4c8#2i4K6u0W2j5$3!0E0i4K6u0r3 ${codename}-proposed main restricted universe multiverse
EOF
# 添加访问符号服务器的秘钥文件
wget -O - 0a9K9s2c8@1M7q4)9K6b7g2)9J5c8W2)9J5c8X3c8V1k6h3u0K6i4K6u0W2N6h3u0#2L8Y4c8#2i4K6u0W2j5$3!0E0i4K6u0r3k6r3u0Y4M7%4W2E0i4K6u0V1M7X3g2D9k6h3q4K6k6g2)9J5k6r3E0W2P5g2)9J5k6h3q4K6j5H3`.`. | sudo apt-key add -
# 更新源文件
sudo apt-get update
deb-src 3dfK9s2c8@1M7q4)9K6b7g2)9J5c8W2)9J5c8X3y4F1i4K6u0W2j5i4u0U0K9r3W2$3k6g2)9J5k6i4g2T1N6h3&6@1N6g2)9J5k6h3y4G2L8g2)9J5c8Y4g2T1N6h3&6@1N6g2)9J5c8R3`.`. xenial main restricted
sudo vim /etv/grub.d/40_custom
#!/bin/sh
exec tail -n +3 $0
# This file provides an easy way to add custom menu entries. Simply type the
# menu entries you want to add after this comment. Be careful not to change
# the 'exec tail' line above.
menuentry 'Ubuntu, KGDB with nokaslr' --class ubuntu --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-simple-bf306d0a-28c8-49c6-bffc-446be272ddcf' {
recordfail
load_video
gfxmode $linux_gfx_mode
insmod gzio
if [ x$grub_platform = xxen ]; then insmod xzio; insmod lzopio; fi
insmod part_msdos
insmod ext2
set root='hd0,msdos1'
if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1 bf306d0a-28c8-49c6-bffc-446be272ddcf
else
search --no-floppy --fs-uuid --set=root bf306d0a-28c8-49c6-bffc-446be272ddcf
fi
echo 'Loading Linux 4.10.0-19 with KGDB built by GEDU lab...'
linux /boot/vmlinuz-4.10.0-19-generic root=UUID=bf306d0a-28c8-49c6-bffc-446be272ddcf ro find_preseed=/preseed.cfg auto noprompt priority=critical locale=en_US quiet kgdbwait kgdb8250=io,03f8,ttyS0,115200,4 kgdboc=ttyS0,115200 kgdbcon nokaslr
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-4.10.0-19-generic
}
sudo update-grub
reboot
stty -F /dev/ttyS0 115200
set architecture i386:x86-64:intel
target remote /dev/ttyS0