Quantcast
Channel: JetsonHacks
Viewing all articles
Browse latest Browse all 339

Jetson Linux Man Pages

$
0
0

Setting up Man Pages for Jetson Linux is easy under JetPack 5, but a few tricks are required for JetPack 4. Looky here:

Background

If you develop on a Linux desktop system, you are accustomed to having “man pages”. Manual pages provide documentation of different commands available in GNU/Linux. There is a lot of information there, the man pages take up about 2GB (!) of drive space.

Here’s the thing. 2GB of drive space is a lot for an embedded system like a Jetson or a Linux server. It’s easier to add the man pages to the system than it is to remove them. Fortunately the Jetson provides a script, unminimize, which will install the man pages. The scripts work great on JetPack 5. However there’s a few tricks to complete on a JetPack 4 install on a machine like a Jetson Nano.

An alternative to consider is to use a web browser to use man pages. Most man pages are available online.

As usual, it’s best to install the man pages on a fresh system before you start developing. The install does a whole lot of shuffling, best not to lose work over it.

JetPack 5

When using JetPack 5, in this case JetPack 5.0.2, installation is straightforward. Open a Terminal. Then:

$ sudo unminimize

Installation will take ~ 50 minutes, depending on the speed of your Internet connection and which Jetson you are using, Xavier or Orin. The man pages take ~ 2GB of drive space.

A difference between the JetPack 5 and JetPack 4 man pages is that the CUDA docs are not available on JetPack 5. The CUDA docs are now exclusively available on the web for CUDA versions shipping with JetPack 5.

JetPack 4

When using JetPack 4, in this case JetPack 4.6.2, installation is a little trickier. Open a Terminal. First:

$ sudo unminimize

This will mostly install the man pages. This main install takes ~ 45 minutes. There will be an error towards the end which relates to dpkg being unable to configure the gconf2 package correctly. In order to fix this:

$ sudo dpkg --configure -a
$ sudo apt purge gconf2
$ sudo apt install gconf2

During the uninstall of gconf2, some other packages are uninstalled. Reinstall them:

$ sudo apt install libbonoboui2-0* libgnome-2-0* libgnome2-common* \
  libgnomeui-0* lignomevfs2-0* libgnomeevfs2-common*

There are differences between issues on JetPack 4 man page installs. We only cover the latest version available a the time of this writing.

In order to find the CUDA man pages, you will need to set the MANPATH environment variable. In the file ~/.bashrc add a line:

export MANPATH=/usr/local/cuda-10.4/doc/man

Where the CUDA version matches the one installed on the system. Then save the file. You will need to either source .bashrc or open a new Terminal for the changes to take effect.

Usage

After manual pages installation, you can use the man program to look up command documentation. Try some of the regular commands to get a feel for what’s available:

$ man man
$ man ls
$ man chmod
$ man wget

With man pages, the world is an oyster, and you are it's pearl!

Web Alternative

Most of the man pages are available online. You can find them with a little bit of hunting. Most people only use man pages when they are writing shell scripts. You don’t frequently may not need to use them, but when you do you need them bad. Here’s some good places to start:

On the CUDA docs, make sure you select the version that you are developing. Bookmark the docs in case you need them. It’s usually slower and requires a bit more hunting than having the pages locally. However, it doesn’t take 45 minutes to download and take up 2GB of drive space

The post Jetson Linux Man Pages appeared first on JetsonHacks.


Viewing all articles
Browse latest Browse all 339

Trending Articles