Hi, On Fri, Sep 26, 2014 at 08:49:36PM -0700, Rusty wrote: > Good morning misc/ > > I purchased a couple of ubequitys edgerouter lite boxes. > > And while the ubequity os is "ok" (better than most small home routers > anyhow) I quickly started missing my obsd, this is why I bought them after > all. > > I am fine netbooting for the time being. however are there any hints to skip > the prompt for the root device? > > you know the one asking for > root device: >
This is configured in sys/kern/subr_disk.c. You can hardcode some of your ethernet ports (e.g., cnmac0) there. However take if you use the same source tree to build to compile from other archs than octeon, because this file is used in all archs. Be sure to put your changes inside #ifdef CPU_OCTEON . I have this in my tree, but take it at your own risk and to be clear: it is a nasty workaround. The only use case for my EdgeMax is for hacking. I would not use them in production until USB supported be concluded, but it is up to you. Regards, Rafael Neves Index: sys/kern/subr_disk.c =================================================================== RCS file: /cvs/src/sys/kern/subr_disk.c,v retrieving revision 1.170 diff -u -p -r1.170 subr_disk.c --- sys/kern/subr_disk.c 14 Sep 2014 14:17:25 -0000 1.170 +++ sys/kern/subr_disk.c 11 Oct 2014 14:28:23 -0000 @@ -1462,11 +1462,18 @@ setroot(struct device *bootdv, int part, printf(")"); } printf(": "); +#ifdef CPU_OCTEON + char *dsklbuf = "cnmac0"; + printf("%s\n", dsklbuf); + strlcpy(buf, dsklbuf, sizeof buf); + len = strlen(buf); +#else s = splhigh(); cnpollc(TRUE); len = getsn(buf, sizeof(buf)); cnpollc(FALSE); splx(s); +#endif /* CPU_OCTEON */ if (strcmp(buf, "exit") == 0) reboot(exitflags); if (len == 0 && bootdv != NULL) { > I would also welcome any hints on updating a diskless set. > My current method is based roughly on the install script. > > detar sets preserving permissions(excepting etc??.tgz) > reboot into arches bsd.rd to rebuild device nodes > reboot and run sysmerge to merge etc??.tgz > > > full serial boot log: > > Looking for valid bootloader image.... > Jumping to start of image at address 0xbfc80000 > > > U-Boot 1.1.1 (UBNT Build ID: 4493936-g009d77b) (Build time: Sep 20 2012 - > 15:48:51) > > BIST check passed. > UBNT_E100 r1:2, r2:14, serial #: DC9FDB803A4D > Core clock: 500 MHz, DDR clock: 266 MHz (532 Mhz data rate) > DRAM: 512 MB > Clearing DRAM....... done > Flash: 4 MB > Net: octeth0, octeth1, octeth2 > > USB: (port 0) scanning bus for devices... 1 USB Devices found > scanning bus for storage devices... > Device 0: Vendor: Prod.: USB DISK 2.0 Rev: PMAP > Type: Removable Hard Disk > Capacity: 3700.6 MB = 3.6 GB (7579008 x 512) > 0 > Interface 0 has 3 ports (RGMII) > Using octeth0 device > TFTP from server 192.168.16.5; our IP address is 192.168.16.16 > Filename 'bsd.sp.octeon'. > Load address: 0x9f00000 > Loading: octeth0: Up 1000 Mbps Full duplex (port 0) > ########################### > > [76/276] > done > Bytes transferred = 3734226 (38fad2 hex), 9855 Kbytes/sec > ELF file is 64 bit > Allocating memory for ELF segment: addr: 0xffffffff81000000 (adjusted to: > 0x1000000), size 0x3bfc70 > Allocated memory for ELF segment: addr: 0xffffffff81000000, size 0x3bfc70 > Processing PHDR 0 > Loading 334bf8 bytes at ffffffff81000000 > Clearing 8b078 bytes at ffffffff81334bf8 > ## Loading Linux kernel with entry point: 0xffffffff81000000 ... > Bootloader: Done loading app on coremask: 0x1 > Total DRAM Size 0x0000000020000000 > Bank 0 = 0x00000000013C0000 -> 0x000000000FFFFFFF > mem_layout[0] page 0x00000000000004F0 -> 0x0000000000003FFF > boot_desc->argv[1] = root=/dev/cnmac0 > Initial setup done, switching console. > boot_desc->desc_ver:7 > boot_desc->desc_size:400 > boot_desc->stack_top:0 > boot_desc->heap_start:0 > boot_desc->heap_end:0 > boot_desc->argc:2 > boot_desc->flags:0x5 > boot_desc->core_mask:0x1 > boot_desc->dram_size:512 > boot_desc->phy_mem_desc_addr:0 > boot_desc->debugger_flag_addr:0xa44 > boot_desc->eclock:500000000 > boot_desc->boot_info_addr:0x1001f0 > boot_info->ver_major:1 > boot_info->ver_minor:2 > boot_info->stack_top:0 > boot_info->heap_start:0 > boot_info->heap_end:0 > boot_info->boot_desc_addr:0 > boot_info->exception_base_addr:0x1000 > boot_info->stack_size:0 > boot_info->flags:0x5 > boot_info->core_mask:0x1 > boot_info->dram_size:512 > boot_info->phys_mem_desc_addr:0x24108 > boot_info->debugger_flags_addr:0 > boot_info->eclock:500000000 > boot_info->dclock:266000000 > boot_info->board_type:20002 > boot_info->board_rev_major:2 > boot_info->board_rev_minor:14 > boot_info->mac_addr_count:3 > boot_info->cf_common_addr:0 > boot_info->cf_attr_addr:0 > boot_info->led_display_addr:0 > boot_info->dfaclock:0 > boot_info->config_flags:0x8 > Copyright (c) 1982, 1986, 1989, 1991, 1993 > The Regents of the University of California. All rights reserved. > Copyright (c) 1995-2014 OpenBSD. All rights reserved. http://www.OpenBSD.org > > OpenBSD 5.6 (GENERIC) #3: Thu Aug 14 15:00:46 CEST 2014 > r...@erl.jasper.la:/usr/src/sys/arch/octeon/compile/GENERIC > real mem = 247709696 (236MB) > avail mem = 245399552 (234MB) > warning: no entropy supplied by boot loader > mainbus0 at root > cpu0 at mainbus0: Cavium OCTEON CPU rev 0.1 500 MHz, Software FP emulation > cpu0: cache L1-I 32KB 8192 way D 16KB 4096 way, L2 128KB 32768 way > clock0 at mainbus0: int 5 > iobus0 at mainbus0 > octcf at iobus0 base 0x1d000800 irq 0 not configured > pcibus at iobus0 irq 0 not configured > cn30xxgmx0 at iobus0 base 0x1180008000000 irq 48 > cnmac0 at cn30xxgmx0: RGMII, address dc:9f:db:80:3a:4d > atphy0 at cnmac0 phy 7: F1 10/100/1000 PHY, rev. 2 > cnmac1 at cn30xxgmx0: RGMII, address dc:9f:db:80:3a:4e > atphy1 at cnmac1 phy 6: F1 10/100/1000 PHY, rev. 2 > cnmac2 at cn30xxgmx0: RGMII, address dc:9f:db:80:3a:4f > atphy2 at cnmac2 phy 5: F1 10/100/1000 PHY, rev. 2 > octrng0 at iobus0 base 0x1400000000000 irq 0 > octhci at iobus0 irq 56 not configured > octrng0 at iobus0 base 0x1400000000000 irq 0 > > [0/276] > octhci at iobus0 irq 56 not configured > uar: ns16550, no working fifo > com0: console > com1 at uartbus0 base 0x1180000000c00 irq 35: ns16550, no working fifo > /dev/ksyms: Symbol table not valid. > vscsi0 at root > scsibus0 at vscsi0: 256 targets > softraid0 at root > scsibus1 at softraid0: 256 targets > root device: cnmac0 > nfs_boot: using interface cnmac0, with revarp & bootparams > nfs_boot: client_addr=192.168.16.16 > nfs_boot: server_addr=192.168.16.5 hostname=erl1 > root on doan:/export/diskless/host/erl1 > WARNING: No TOD clock, believing file system. > WARNING: CHECK AND RESET THE DATE! > swap on doan:/export/diskless/swap/erl1 > Automatic boot in progress: starting file system checks. > setting tty flags > pf enabled > starting network > starting early daemons: syslogd pflogd ntpd. > starting RPC daemons:. > swapctl: adding doan:/export/diskless/swap/erl1 as swap device at priority 0 > savecore: /bsd: kvm_read: version misread > checking quotas: done. > kvm_mkdb: can't open /dev/ksyms > clearing /tmp > kern.securelevel: 0 -> 1 > creating runtime link editor directory cache. > preserving editor files. > starting network daemons: sshd smtpd sndiod. > /etc/rc.local[1]: cannot create /var/log/dmesg/2014-09-15T01:32.dmesg: No > such file or directory > starting local daemons: cron. > Mon Sep 15 01:32:30 PDT 2014 > > OpenBSD/octeon (erl1.redacted.net) (console) > > login: