User Tools

  • (equal to forum credentials)

Site Tools


faq

This is an old revision of the document!


FAQ

This page contains answers and solutions to Frequently Asked Questions and/or common issues.

Changing SSH port

“How do I change the SSH port?”

On XBian the SSH daemon runs behind inetd. That's why you have to change the listening port in /etc/services instead of in /etc/ssh/sshd_config. Alternatively you can configure SSH to start in standalone mode - that way you can still use the /etc/ssh/sshd_config file to set the port.

Changing SSH port when using inetd

Edit /etc/services with your preferred text editor and find the following 2 lines:

ssh        22/tcp                # SSH Remote Login Protocol
ssh        22/udp

Then change ”22” to your desired port. Afterwards restart inetd to apply the change:

$ sudo restart openbsd-inetd

Changing SSH port when using standalone mode

To enable the standalone mode, remove the line ”manual” from /etc/init/ssh-hid.override. You can now change the port in /etc/ssh/sshd_config and then start the service with

$ sudo start ssh-hid

Run a script at startup

“How do I get a script running automatically at startup?”

The easiest way to do so, is editing the file /etc/rc.local. In this file you can put in any command you want to run at startup. There are three important things you have to consider:

  • your command must be put before the line exit(0)
  • by default commands in /etc/rc.local are executed as root
  • to keep the command running in the background you have to end the command with an &

Example:

If you want to run the script as user xbian and keep the script running in the background, you have to add a line like this:

su xbian -c "/path/script &"

before the exit(0) line in /etc/rc.local.

If you want to run the script as root, adding the part in the quotes (/path/script &) is already enough.
If it's a command which shouldn't stay running in the background, you have to remove the & sign at the end.

Change CuBox-I cmdline paramaters

Edit the /boot/boot.src.txt'file and run /boot/mks afterwards.

faq.1404292159.txt.gz · Last modified: 2014/07/02 11:09 by curlymo