Skip to content

Commit 0efb823

Browse files
committed
update unix commands
1 parent 06bd254 commit 0efb823

File tree

1 file changed

+34
-19
lines changed

1 file changed

+34
-19
lines changed

docs/source/docs/troubleshooting/unix-commands.md

Lines changed: 34 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,45 +1,56 @@
1-
Useful Unix Commands
2-
====================
1+
# Useful Unix Commands
32

4-
SSH
5-
---
3+
## SSH
64

75
[SSH (Secure Shell)](https://www.mankier.com/1/ssh) is used to securely connect from a local to a remote system (ex. from a laptop to a coprocessor). Unlike other commands on this page, ssh is not Unix specific and can be done on Windows and MacOS from their respective terminals.
86

97
:::{note}
10-
You may see a warning similar to `The authenticity of host 'xxx' can't be established...` or `WARNING: REMOTE HOST IDENTIFICATION HAS CHANGED!`, in most cases this can be safely ignored if you have confirmed that you are connecting to the correct host over a secure connection, and the fingerprint will change when your operating system is reinstalled or PhotonVision's coprocessor image is re-flashed. You can read more about it [here](https://superuser.com/questions/421997/what-is-a-ssh-key-fingerprint-and-how-is-it-generated)
8+
You may see a warning similar to `The authenticity of host 'xxx' can't be established...` or `WARNING: REMOTE HOST IDENTIFICATION HAS CHANGED!`, in most cases this can be safely ignored if you have confirmed that you are connecting to the correct host over a secure connection, and the fingerprint will change when your operating system is reinstalled or PhotonVision's coprocessor image is re-flashed. This can also occur if you have multiple coprocessors with the same hostname on your network. You can read more about it [here](https://superuser.com/questions/421997/what-is-a-ssh-key-fingerprint-and-how-is-it-generated)
119
:::
1210

1311
Example:
1412

1513
:::{code-block}
16-
ssh username@hostname
14+
ssh pi@hostname
1715
:::
1816

19-
ip
20-
---
17+
For PhotonVision, the username will be `pi` and the password will be `raspberry`.
18+
19+
## ip
2120

2221
Run [ip address](https://www.mankier.com/8/ip) with your coprocessor connected to a monitor in order to see its IP address and other network configuration information.
2322

23+
Your output might look something like this:
24+
25+
:::{code-block}
26+
2: end1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 1000
27+
link/ether de:9a:8f:7d:31:aa brd ff:ff:ff:ff:ff:ff
28+
inet 10.88.47.12/24 brd 10.88.47.255 scope global dynamic noprefixroute end1
29+
valid_lft 27367sec preferred_lft 27367sec
30+
31+
:::
32+
33+
In this example, the numbers following `inet` (10.88.47.12) are your IP address.
2434

25-
SCP
26-
---
35+
## SCP
2736

2837
[SCP (Secure Copy)](https://www.mankier.com/1/scp) is used to securely transfer files between local and remote systems.
2938

3039
Example:
3140

3241
:::{code-block}
33-
scp [file] username@hostname:/path/to/destination
42+
scp [file] pi@hostname:/path/to/destination
3443
:::
3544

36-
SFTP
37-
---
45+
## SFTP
3846

3947
[SFTP (SSH File Transfer Protocol)](https://www.mankier.com/1/sftp#) is another option for transferring files between local and remote systems.
4048

41-
v4l2-ctl
42-
---
49+
## Filezilla
50+
51+
[Filezilla](https://filezilla-project.org/) is a GUI alternative to SCP and SFTP. It is available for Windows, MacOS, and Linux.
52+
53+
## v4l2-ctl
4354

4455
[v4l2-ctl](https://www.mankier.com/1/v4l2-ctl) is a command-line tool for controlling video devices.
4556

@@ -65,8 +76,7 @@ v4l2-ctl --list-ctrls --device path/to/video_device
6576
This command is especially useful in helping to debug when certain camera controls, like exposure, aren't behaving as expected. If you see an error in the logs similar to `WARNING 30: failed to set property [property name] (UsbCameraImpl.cpp:646)`, that means that PhotonVision is trying to use a control that doesn't exist or has a different name on your hardware. If you encounter this issue, please [file an issue](https://github.com/PhotonVision/photonvision/issues) with the necessary logs and output of the `v4l2-ctl --list-ctrls` command.
6677
:::
6778

68-
systemctl
69-
---
79+
## systemctl
7080

7181
[systemctl](https://www.mankier.com/1/systemctl) is a command that controls the `systemd` system and service manager.
7282

@@ -88,8 +98,13 @@ Restart PhotonVision:
8898
systemctl restart photonvision
8999
:::
90100

91-
journalctl
92-
---
101+
Check the status of PhotonVision:
102+
103+
:::{code-block}
104+
systemctl status photonvision
105+
:::
106+
107+
## journalctl
93108

94109
[journalctl](https://www.mankier.com/1/journalctl) is a command that queries the systemd journal, which is a logging system used by many Linux distributions.
95110

0 commit comments

Comments
 (0)