aboutsummaryrefslogtreecommitdiffstats
path: root/tools/create-gce-image.sh
Commit message (Collapse)AuthorAgeFilesLines
* tools: correct resolv.conf filename for nameserver configurationRichard Smith2024-06-051-1/+1
| | | | Signed-off-by: Richard Smith <happyercat@gmail.com>
* tools/create-gce-image: add rootwait command line option for ppc64leAndrew Donnellan2023-07-241-1/+1
| | | | | | | | | | | Sometimes it can take a while for a root block device to appear when backed by hardware that is slow to initialise, e.g. the ibmvfc Virtual Fibre Channel interface. Use the "rootwait" option to have the kernel wait for a disk to appear rather than panicking immediately. Signed-off-by: Andrew Donnellan <ajd@linux.ibm.com>
* tools/create-gce-image.sh: don't use a fixed root device path on ppc64leAndrew Donnellan2023-07-241-1/+1
| | | | | | | | There's no need to hardcode the GRUB device path for the root device - that makes assumptions about how the partition firmware behaves. Just use GRUB's search command to determine it dynamically. Signed-off-by: Andrew Donnellan <ajd@linux.ibm.com>
* tools/create-gce-image.sh: use DOS MBR instead of GPT for ppc64le imagesAndrew Donnellan2023-07-241-3/+3
| | | | | | | | Some versions of PowerVM Partition Firmware have trouble handling GPT partition tables on boot devices. Use MBR partition tables to avoid compatibility issues. Signed-off-by: Andrew Donnellan <ajd@linux.ibm.com>
* tools/create-gce-image.sh: enable sftp in ssh daemonAlexander Egorenkov2022-05-101-0/+1
| | | | | | | | | | | | | | | | | | | If we don't enable SFTP in SSH daemon, then scp will not work w/o -O option. Fixes: syz-ci-devel | 2022/05/10 09:01:23 syz-ci-devel-kasan: VM testing failed with: failed to copy test binary to VM: failed to run ["scp" "-P" "55610" "-F" "/dev/null" "-o" "UserKnownHostsFile=/dev/null" "-o" "BatchMode=yes" "-o" "IdentitiesOnly=yes" "-o" "StrictHostKeyChecking=no" "-o" "ConnectTimeout=10" "/workdir/syzkaller/current/bin/linux_s390x/syz-fuzzer" "root@localhost:/syz-fuzzer"]: exit status 255 syz-ci-devel | Warning: Permanently added '[localhost]:55610' (ED25519) to the list of known hosts. syz-ci-devel | subsystem request failed on channel 0 syz-ci-devel | scp: Connection closed Signed-off-by: Alexander Egorenkov <eaibmz@gmail.com>
* dashboard/config/linux: remove panic_on_warn from kcsan/kmsanDmitry Vyukov2021-03-031-1/+1
| | | | These instances ignore WARNINGs, so they don't want panic_on_warn.
* tools/create-gce-image.sh: setup ssh with empty passwordDmitry Vyukov2021-01-291-15/+13
| | | | | | We used to use ssh keys, but there are no partiuclar advantages of using key over empty password. It just makes things more complex. And the new image building code in pkg/build does not support keys.
* tools/create-gce-image.sh: remove unused SYZ_VM_TYPEDmitry Vyukov2021-01-291-15/+0
|
* tools/create-gce-image.sh: move sysctl's to executorDmitry Vyukov2020-11-211-2/+0
| | | | | | | | | Move the remaining sysctls from image creation scripts into executor. We have the rest in executor now, and these are captured in reproducers and are not duplicated. It seems that ping_group_range was accidentially lost along the way, re-add it.
* tools: add script to check shebang lines (#2234)Mark Johnston2020-11-021-1/+1
| | | | | | | | | | | * pkg/vcs: remove obsolete test script Per Dmitry, this should have been removed as part of 8f58e4b ("pkg/bisect: switch to kconfig.Minimize"). * all: convert shebang lines to use /usr/bin/env * Makefile: fix non-portable use of find(1)
* tools/create-gce-image.sh: drop rodata=nDmitry Vyukov2020-10-011-5/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | There is suspicion that the random programs corrupt .text segment: https://groups.google.com/g/syzkaller-bugs/c/d5GC1V8S34k/m/6LTarP8mBAAJ which leads to a number of assorted confusing crashes: https://syzkaller.appspot.com/bug?extid=ce179bc99e64377c24bc Turns out we disable text ro protection with rodata=n. The comment says that's because it's slow with KASAN, but most likely what was slow is actually additional debug checking due to CONFIG_DEBUG_WX. If we don't enable CONFIG_DEBUG_WX (which we don't), rodata itself should be fine and desirable. My experiment with the latest kernel does not show any noticable slowdown without rodata=n: [ 11.985152][ T1] Freeing unused kernel image (initmem) memory: 3432K [ 11.986129][ T1] Write protecting the kernel read-only data: 147456k [ 11.990863][ T1] Freeing unused kernel image (text/rodata gap) memory: 2012K [ 11.992797][ T1] Freeing unused kernel image (rodata/data gap) memory: 1324K [ 11.993895][ T1] Run /sbin/init as init process [ 11.910396][ T1] Freeing unused kernel image (initmem) memory: 3432K [ 11.911277][ T1] Kernel memory protection disabled. [ 11.911984][ T1] Run /sbin/init as init process
* tools/create-gce-image.sh: mount the root filesystem read-writeRadoslav Gerganov2020-09-231-0/+1
| | | | | | | Add fstab entry to mount the root filesystem read-write after boot. This has been done with commit 873745 for create-image.sh. Maybe this hint is not necessary for GCE but it is required when running on other platforms (e.g. VMware).
* tools/create-gce-image.sh: support s390xAlexander Egorenkov2020-09-141-2/+7
| | | | Signed-off-by: Alexander Egorenkov <Alexander.Egorenkov@ibm.com>
* tools: add udev rule for i915Zubin Mithra2020-07-171-0/+3
| | | | | | | Add a udev rule to create /dev/i915, a symlink to /dev/dri/card#. This prevents i915 related syscalls from being exercised during fuzzing if the driver is not used.
* tools: add custom udev rules to generated imagesRicardo Cañuelo2020-06-101-0/+4
| | | | | | | | Add a default udev rule file to the image creation process in create-gce-image.sh and create-image.sh. This change creates a default rule to make udev create a custom-named symlink for the specific vim2m device.
* tools/create-gce-image.sh: fix sysctl.kernel.hung_task_all_cpu_backtrace=1Dmitry Vyukov2020-03-311-2/+1
| | | | | Turns out this is not a sysctl, even though it's prefixed with sysctl: https://groups.google.com/d/msg/syzkaller/EJP7uvY4O-c/XLrhrBqGAQAJ
* tools/create-gce-image.sh: enable sysctl.kernel.hung_task_all_cpu_backtrace=1Dmitry Vyukov2020-03-301-0/+1
| | | | | The format of this knob has changed again: https://groups.google.com/d/msg/syzkaller/EJP7uvY4O-c/XLrhrBqGAQAJ
* tools, dashboard: move net.ifnames=0 to create-gce-image.shAndrey Konovalov2020-03-281-2/+2
| | | | Looks like it affects not only android-5.4.
* executor, sys/linux: add ath9k usb descriptionsAndrey Konovalov2020-03-131-1/+1
| | | | | | | Among other things this changes timeout for USB programs from 2 to 3 seconds. ath9k fuzzing also requires ath9k firmware to be present, so system images need to be regenerated with the updated script.
* tools/create-gce-image.sh: Generate ppc64le pseries disk imagesAndrew Donnellan2019-05-031-8/+52
| | | | | | | | | | | | | Add support for generating ppc64le pseries disk images. This will create a disk image with a PowerPC PReP boot partition at the start, and install the IEEE1275/OpenFirmware version of GRUB. If we ever support the powernv platform in the future we're going to have to do something different here. Add a command line argument to specify architecture, defaulting to amd64. Signed-off-by: Andrew Donnellan <andrew.donnellan@au1.ibm.com>
* tools/create-gce-image.sh: create ext4 image without journallingDmitry Vyukov2018-10-151-1/+1
| | | | | | We don't need consistent image after reboot since we always reimage. We know of some use cases that don't use journalling, but don't know of any that use journalling.
* tools/create-gce-image.sh: mount securityfs and configfsDmitry Vyukov2018-09-261-0/+2
|
* tools/create-gce-image.sh: disable ftrace_dump_on_oopsDmitry Vyukov2018-09-101-1/+1
| | | | | | | We don't have anything useful there. But sometimes fuzzer somehow poppulates it with some nonsense, and then it all dumped in crashes. Disable it.
* tools/create-gce-image.sh: auto-detect block device typeDmitry Vyukov2018-09-071-6/+18
| | | | | | | Currently we choose block device to use (nbd/loop) based on SYZ_VM_TYPE. Strictly saying these things are orthogonal. losetup is broken on Ubuntu. qemu-nbd is broken on Debian. Try to auto-detect what will work based on uname.
* dashboard/config: re-enable selinuxDmitry Vyukov2018-09-051-3/+0
| | | | | | | Upstream "selinux: fix mounting of cgroup2 under older policies" commit fixes mounting of cgroup2 under wheezy selinux policy. So don't disable selinux on start. Create separate cmdline arguments that enable selinux and apparmor.
* tools/create-gce-image.sh: add default ext4 optionsDmitry Vyukov2018-09-031-1/+1
| | | | Set some realistic modern ext4 options when creating the image.
* tools/create-gce-image.sh: support both nbd and loopDmitry Vyukov2018-05-171-17/+37
| | | | | Pass target OS/arch and VM type to kernel.CreateImage. Use nbd for gce and loop for qemu VM type.
* tools/create-gce-image.sh: support MKE2FS_CONFIGDmitry Vyukov2018-05-161-1/+2
|
* tools/create-gce-image.sh: revert loop to nbdDmitry Vyukov2018-05-141-12/+14
| | | | | | loop devices are nice, but unfortunately this creates images that does not boot on GCE. Reason is unclear. Revert back to nbd for now.
* tools/create-gce-image.sh: use loop instead of nbdDmitry Vyukov2018-05-141-18/+19
| | | | | | | | | | | loop is much more standard than nbd and does not require additional modules. nbd broke on Debian rolling. loop also allows parallel execution thanks to losetup -f. Use loop instead of nbd. Also improve cleanup logic and add one missing sudo. Update #501
* sys/linux: test various binfmt's in execveDmitry Vyukov2018-04-021-0/+1
|
* sys/linux: add cgroup descriptionsDmitry Vyukov2018-03-251-0/+3
|
* tools: include selinux packages when building imagesDmitry Vyukov2017-12-081-1/+1
| | | | These packages are required to actually activate selinux during boot.
* sys/linux: add binder descriptionsDmitry Vyukov2017-11-271-0/+4
|
* tools/create-gce-image.sh: explicitly specify target for grubDmitry Vyukov2017-08-111-1/+1
| | | | | | | | | On most distributions default grub target is i386-pc, which works. However, on some default is x86_64-efi, which fails with: grub-install: error: cannot find EFI directory. Explicitly specify i386-pc target.
* tools/create-gce-image.sh: ignore SIGINTDmitry Vyukov2017-07-171-0/+5
| | | | | | If the script is aborted at an unfortunate point, it leaves the whole system broken. E.g. we've seen that fdisk cannot update partition table until the next reboot. If you really need to kill it, use a different signal. But better wait.
* pkg/kernel: actually pass cmdline/sysctl files to the build scriptDmitry Vyukov2017-07-171-2/+4
|
* syz-ci: allow to specify cmdline/sysctlsDmitry Vyukov2017-07-171-5/+20
| | | | | Allow to specify per-kernel command line and sysctl values to more closely mimic the target kernel.
* vm/gce: accept un-tar-ed imageDmitry Vyukov2017-06-171-22/+17
| | | | | | | | | | vm/gce differs from other VM types in that it accepts image in a weird, GCE-specific format (namely, image named disk.raw is put into .tar.gz file). This makes it impossible to write generic code that creates images for any VM types. Make vm/gce accept just image like e.g. vm/qemu and handle own specifics internally.
* tools/create-gce-image.sh: don't use verbose output for tar invocationDmitry Vyukov2017-06-171-2/+2
|
* tools/create-gce-image.sh: add nmi_watchdog=panic to cmd lineDmitry Vyukov2017-06-151-1/+1
|
* tools: more reliable network config in create-gce-image.shDmitry Vyukov2017-06-031-1/+1
| | | | | | Currently we append to /etc/network/interfaces, which can lead to duplicate lo entry. Write out the whole interfaces file instead.
* prog, sys: add icmp descriptions and checksumAndrey Konovalov2017-02-061-0/+1
|
* tools/create-image.sh: add psmisc package for killallDmitry Vyukov2017-01-241-0/+1
| | | | + raise console output level, otherwise stack traces may be dropped
* syz-gce: support continous buildDmitry Vyukov2017-01-161-5/+5
| | | | | Add "local" mode in which syz-gce clones, builds and monitors for updates a linux kernel repo.
* vm/qemu: add some kvm-related kernel cmd line flagsDmitry Vyukov2017-01-091-1/+1
| | | | | In particular it is useful to enable nested. Enable a bunch of others as well.
* vm/qemu: enable more kvm features in test kernelDmitry Vyukov2017-01-091-1/+1
|
* tools/create-image.sh: use net.core.bpf_jit_enable = 1Dmitry Vyukov2016-12-071-1/+1
| | | | | bpf_jit_enable = 2 causes printing of all programs to console. Produces lots of output and is not very useful. Disable it.
* tools: fix getty configuration in create-gce-image.shDmitry Vyukov2016-11-281-1/+1
|
* tools/create-gce-image.sh: enable bpf jit and update commentsDmitry Vyukov2016-11-161-3/+5
|