Results 1 to 8 of 8

Thread: serial console

  1. #1
    Junior Member
    Join Date
    Aug 2014
    Posts
    7

    serial console

    I'm booting Knoppix on a board which does not have a VGA port.

    How do I redirect the console out COM1?

    By default, Knoppix boots as follows (thank you Werner for pointing me to the instructions on how to install Knoppix on this CF card):

    ======================================
    PC Engines ALIX.2 v0.99m
    640 KB Base Memory
    261120 KB Extended Memory

    01F0 Master 848A CF CARD
    Phys C/H/S 15490/16/63 Log C/H/S 971/255/63 LBA

    SYSLINUX 4.04 EDD 20110711 Copyright (C) 1994-2011 H. Peter Anvin et al
    boot: knoppix
    Loading linux......
    Loading minirt.gz...ready.
    ======================================

    But I see nothing further, after that last 'Loading minirt.gz...ready.' line. And hitting 'Enter' does not produce a result.


    I tried adding 'console=tty0 console=ttyS0,38400n8' as cheat codes. Also, 'console=tty0 console=ttyS1,38400n8'.

    DEFAULT knoppix
    APPEND ramdisk_size=100000 lang=en vt.default_utf8=0 apm=power-off initrd=minirt.gz nomce libata.force=noncq hpsa.hpsa_allow_any=1 loglevel=1 tz=localtime console=tty0 console=ttyS1,38400n8
    TIMEOUT 100
    # TOTALTIMEOUT 20
    # KBDMAP german.kbd
    PROMPT 1
    F1 boot.msg
    F2 f2
    F3 f3
    [...]


    But adding these two 'cheat code' does not change the behavior.

    Is there a different 'cheat code' other than 'console' that I want to investigate?

    --sk

    Stuart Kendrick

  2. #2
    Senior Member registered user
    Join Date
    Feb 2010
    Posts
    512
    Hello Stuart Kendrick,

    I think the first serial port is called ttyS0.

  3. #3
    Junior Member
    Join Date
    Aug 2014
    Posts
    7
    I've tried a few variants, same behavior:

    DEFAULT knoppix
    APPEND ramdisk_size=100000 lang=en vt.default_utf8=0 apm=power-off initrd=minirt.gz nomce libata.force=noncq hpsa.hpsa_allow_any=1 loglevel=1 tz=localtime console=ttyS0,38400n8

    DEFAULT knoppix 2
    APPEND ramdisk_size=100000 lang=en vt.default_utf8=0 apm=power-off initrd=minirt.gz nomce libata.force=noncq hpsa.hpsa_allow_any=1 loglevel=1 tz=localtime console=ttyS0,38400n8

    DEFAULT knoppix
    APPEND ramdisk_size=100000 lang=en vt.default_utf8=0 apm=power-off initrd=minirt.gz nomce libata.force=noncq hpsa.hpsa_allow_any=1 loglevel=1 tz=localtime console=/dev/tty0 console=ttyS0,38400n8

    DEFAULT knoppix
    APPEND ramdisk_size=100000 lang=en vt.default_utf8=0 apm=power-off initrd=minirt.gz nomce libata.force=noncq hpsa.hpsa_allow_any=1 loglevel=1 tz=localtime console=tty0 console=ttyS0,38400n8

    DEFAULT knoppix
    APPEND ramdisk_size=100000 lang=en vt.default_utf8=0 apm=power-off initrd=minirt.gz nomce libata.force=noncq hpsa.hpsa_allow_any=1 loglevel=1 tz=localtime nomodeset console=ttyS0,38400n8

    DEFAULT knoppix
    APPEND ramdisk_size=100000 lang=en vt.default_utf8=0 apm=power-off initrd=minirt.gz nomce libata.force=noncq hpsa.hpsa_allow_any=1 loglevel=1 tz=localtime noddc nocomposite nodrm nofb nomodeset console=tty0 console=ttyS0,38400n8

    DEFAULT knoppix
    APPEND ramdisk_size=100000 lang=en vt.default_utf8=0 apm=power-off initrd=minirt.gz nomce libata.force=noncq hpsa.hpsa_allow_any=1 loglevel=1 tz=localtime noddc nocomposite nodrm nofb nomodeset console=ttyS0,38400n8

    Puzzling isn't it? Serial consoles configuration is fairly documented ... I've been using this:
    http://www.tldp.org/HOWTO/Remote-Ser...re-kernel.html

    Other tips?

    --sk

  4. #4
    Senior Member registered user
    Join Date
    Feb 2010
    Posts
    512
    Are you sure that serial support has been compiled into the kernel?
    I think it is also necessary to edit /etc/inittab if you want remote login using a serial port.

  5. #5
    Junior Member
    Join Date
    Aug 2014
    Posts
    7
    To create the CF disk, I booted a PC with Knoppix 6.7.0 and chose "Preferences... Install KNOPPIX to flash disk".

    The PC Engines box into which I have inserted the CF disk does not have a VGA port, ergo my pursuing the serial console.

    - How do I tell if serial support has been compiled into the kernel?
    - Myself, I don't see a way to edit /etc/inittab until the box has booted (and I have a serial console from which to run "vi /etc/inittab" -- do you see a path toward doing this?

    --sk

  6. #6
    Junior Member
    Join Date
    Aug 2014
    Posts
    7

    ssh path

    I also tried loading sshd on boot, by doing the following:

    Adding 'myconfig=scan' to the Default APPEND list
    Creating /KNOPPIX/knoppix.sh:
    #!/bin/bash
    cd /etc/ssh sudo
    ssh-keygen -t rsa -f ssh_host_rsa_key -C '' -N ''
    sudo chmod 600 ssh_host_rsa_key
    sudo chmod 644 ssh_host_rsa_key.pub
    sudo ssh-keygen -t dsa -f ssh_host_dsa_key -C '' -N ''
    sudo chmod 600 ssh_host_dsa_key
    sudo chmod 644 ssh_host_dsa_key.pub
    /etc/init.d/ssh start

    However, the box isn't requesting a DHCP address -- I make this claim based on the following evidence:
    - Wireshark doesn't see any DHCP broadcasts on this subnet during the boot period
    - My DHCP server doesn't register any additional addresses

    So, I'm guessing that the Knoppix boot process is stalling somewhere. Which brings me back to wanting serial console access.

    --sk

  7. #7
    Senior Member registered user
    Join Date
    Feb 2010
    Posts
    512

    No console output on serial port in Knoppix 6.7.0

    - How do I tell if serial support has been compiled into the kernel?
    Hi Stuart Kendrick,

    now I am able to answer your question.

    My first step was to run Knoppix 6.7.0 CD inside a virtual machine I usually use for Knoppix 7.2. There is a virtual HDD connected to this virtual machine. I created a new directory on this virtual HDD an copied the the kernel configuration file /boot/config-2.6.39.63 of Knoppix 6.7.0 into this directory. I downloaded the latest Linux source for kernel version 2.6 from kernel.org and the tar.xz archive in this directory.

    I shut down Knoppix 6.7.0 and booted Knoppix 7.2.0 inside the virtual machine. My install of Knoppix 7.2.0 is already configured to compile Linux kernels from source. I changed to the directory I mentioned above and extracted the tar.xz archive. There was a new directory called linux-2.6.32.63. I copied the kernel configuration file of Knoppix 6.7.0 into this directory and gave it the new name .config
    Code:
    cp config-2.6.39.63 linux-2.6.32.63/.config
    Then I changed to this directory and issued
    Code:
    make menuconfig
    I think this is the easiest way to examine the kernel configuration of Knoppix 6.7.0. I found out that Knoppix 6.7.0 was not configured to use the serial port for console output.

    If you want to use serial port for console output you have to enable serial communications to the console. Support has to be compiled into the kernel. You cannot use a kernel module.

    If you like to compile your own Linux kernel you will find the setting under: device drv → char → serial → 8250/16550 → Console

  8. #8
    Junior Member
    Join Date
    Aug 2014
    Posts
    7
    Klaus, thank you for going to all this trouble to investigate this issue on my behalf -- this is a deeper investigation than I would have had the skills to pursue.

    I think at this point I am stuck -- what I really want to do is to use this Alix board to host the freely available WANem product (built on top of Knoppix 6.7.0) ... but the WANem source is not available to me. Sounds like my hardware will not support this project.

    Thank you for bringing clarity to my situation.

    --sk

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Dell PowerEdge M610 Blade Server E5620@2.2GHZ (6x)8GB RAM (2x)146GB 15K SAS HDD picture

Dell PowerEdge M610 Blade Server E5620@2.2GHZ (6x)8GB RAM (2x)146GB 15K SAS HDD

$75.00



Dell PowerEdge R720XD Xeon E5-2680 V2 2.8GHz 20 Cores 256GB RAM 12x4TB picture

Dell PowerEdge R720XD Xeon E5-2680 V2 2.8GHz 20 Cores 256GB RAM 12x4TB

$510.00



DELL PowerEdge R730 Server 2x E5-2690v3 2.6GHz =24 Cores 32GB H730 4xRJ45 picture

DELL PowerEdge R730 Server 2x E5-2690v3 2.6GHz =24 Cores 32GB H730 4xRJ45

$275.00



Dell PowerEdge R630 2x Xeon E5-2630 V4 2.20GHZ 128GB DDR4-2133MHZ 2x 750W PSU picture

Dell PowerEdge R630 2x Xeon E5-2630 V4 2.20GHZ 128GB DDR4-2133MHZ 2x 750W PSU

$170.95



Dell PowerEdge R730XD 28 Core Server 2X Xeon E5-2680 V4 H730 128GB RAM No HDD picture

Dell PowerEdge R730XD 28 Core Server 2X Xeon E5-2680 V4 H730 128GB RAM No HDD

$389.99



Dell PowerEdge R730, 2 sinks, SystemBoard, 8 trays,H330,Idrac 8 exp, 2x750w Psu picture

Dell PowerEdge R730, 2 sinks, SystemBoard, 8 trays,H330,Idrac 8 exp, 2x750w Psu

$135.00



Dell PowerEdge R620 Server 2x Xeon  E5-2620 @ 2.0GHz 64GB RAM NO HDDs picture

Dell PowerEdge R620 Server 2x Xeon E5-2620 @ 2.0GHz 64GB RAM NO HDDs

$108.96



Dell PowerEdge R620 Server - 256GB RAM, 2x8c CPU, 128Gb SSD/3x600Gb SAS, Proxmox picture

Dell PowerEdge R620 Server - 256GB RAM, 2x8c CPU, 128Gb SSD/3x600Gb SAS, Proxmox

$320.00



DELL PowerEdge R630 8SFF Server 2x E5-2690v4 2.6GHz =28 Cores 128GB H730 4xRJ45 picture

DELL PowerEdge R630 8SFF Server 2x E5-2690v4 2.6GHz =28 Cores 128GB H730 4xRJ45

$444.00



Dell PowerEdge R430 3.5 1U 2x E5-2666 v3 2.9ghz 20-Cores 128gb 4x Trays 2x 550w picture

Dell PowerEdge R430 3.5 1U 2x E5-2666 v3 2.9ghz 20-Cores 128gb 4x Trays 2x 550w

$289.99