Skip to content

Commit 8cfa01d

Browse files
committed
Simplify Linux install instructions
Downloading and making Pelican available is currently a one-liner in bash on almost all distributions (would be curious if someone found one where this doesn't work). However, we somehow made this one-liner into a daunting multi-page document. This is my attempt to simplify as much as possible.
1 parent 3c4dce6 commit 8cfa01d

File tree

1 file changed

+64
-30
lines changed

1 file changed

+64
-30
lines changed

docs/pages/install/linux-binary.mdx

Lines changed: 64 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -1,73 +1,107 @@
1-
# Install Pelican as a standalone binary on Linux
1+
# Install Pelican as unprivileged Linux user
22

3-
This document explains how to install Pelican on a Linux operating system as a standalone binary.
3+
This document explains how to install Pelican on a Linux operating system as a standalone binary without any special administrator privileges.
4+
5+
## Quickstart
6+
7+
To download the latest version of Pelican and unpack it into the default location for user binaries on most Linux hosts, copy/paste
8+
the following into a terminal:
9+
10+
```bash
11+
wget -O - "https://dl.pelicanplatform.org/latest/pelican_$(uname -s)_$(uname -m).tar.gz" | tar zx -C ~/.local/bin/ --strip-components=1
12+
```
13+
14+
To test the binary, execute:
15+
16+
```bash
17+
pelican --version
18+
```
19+
20+
If a version number did not print, then you may have a special platform or configuration on your host; follow the subsequent sections. Otherwise, you're done and may follow the [Next Steps](#next-steps).
421

522
## Download Pelican Binary
623

7-
1. Navigate to [Pelican download page](../install.mdx#download-pelican-binary) and select the Pelican standalone binary you want to install.
24+
1. Navigate to the [Pelican download page](../install.mdx#download-pelican-binary) to select the Pelican standalone binary you want to install.
825

9-
2. In **Operating System** section, select **Linux**. In **Architectures** section, select **X86_64** or **AMR64** depending on the architecture of your machine.
26+
2. In **Operating System** section, select **Linux**. In **Architectures** section, select **X86_64** or **ARM64** depending on the architecture of your machine.
1027

11-
3. In the list of candidates, copy the link to `pelican_Linux_x86_64.tar.gz` if you select **X86_64**, or `pelican_Linux_arm64.tar.gz` if you select **ARM64**.
28+
3. In the list of candidates, copy the link to `pelican_Linux_x86_64.tar.gz` or `pelican_Linux_arm64.tar.gz`, as appropriate.
1229

1330
4. Change the following command with the link to the binary you copied in the previous step and run the command
1431

1532
```bash
1633
wget <replace-with-the-link-you-copied>
17-
tar -zxvf pelican_Linux_x86_64.tar.gz # x86_64 user
34+
mkdir -p ~/.local/bin
35+
tar -zxvf -C ~/.local/bin/ --strip-components=1 pelican_Linux_$(uname -m).tar.gz
1836
```
1937

20-
> **Note**: You need to replace `pelican_Linux_x86_64.tar.gz` with `pelican_Linux_arm64.tar.gz` if you are running an `ARM64` machine.
38+
> **Note**: The shell should expand `$(uname -m)` with the machine's hardware platform. If it fails, you may need to replace the filename with `pelican_Linux_x86_64.tar.gz` with `pelican_Linux_arm64.tar.gz`, as appropriate.
2139
2240
Example to install Pelican standalone binary on an `X86_64` machine:
2341

2442
```bash
25-
wget https://github.com/PelicanPlatform/pelican/releases/download/v7.5.8/pelican_Linux_x86_64.tar.gz
26-
tar -zxvf pelican_Linux_x86_64.tar.gz
43+
$ wget https://dl.pelicanplatform.org/latest/pelican_Linux_x86_64.tar.gz
44+
$ mkdir -p ~/.local/bin
45+
$ tar -zxvf -C ~/.local/bin/ --strip-components=1 pelican_Linux_x86_64.tar.gz
2746
```
2847

29-
## Add Pelican Binary to `PATH`
48+
## Make Pelican Binary Available
3049

31-
The above command extracted the binary from the `tar` file. You may run the binary in the current folder, but it is recommended that you add Pelican binary to your `PATH` environment variable to allow `pelican` to be called directly from your command line.
50+
The above command extracted the binary from the `tar` file and placed it inside `.local/bin/` in your home directory. On most Linux distributions, this makes the binary automatically available.
3251

33-
> **Note**: You need to replace `pelican_Linux_x86_64` with `pelican_Linux_arm64` if you are running an `ARM64` machine and downloaded `pelican_Linux_arm64.tar.gz`.
34-
35-
### Run Pelican binary from the downloaded folder:
52+
You may test this by running:
3653

3754
```bash
38-
$ cd pelican_Linux_x86_64 # Go to the binary folder
39-
$ ./pelican --version # Run Pelican binary
55+
command -v pelican
56+
```
4057

41-
Version: 7.5.8
42-
Build Date: 2024-03-01T18:13:00Z
43-
Build Commit: d260a07d3b057d19b7fdd36125f91a8768531258
44-
Built By: goreleaser
58+
If it outputs a path like this example:
59+
60+
```bash
61+
$ command -v pelican
62+
/home/username/.local/bin/pelican
4563
```
4664

65+
then you may skip this section. If not, you need to alter the `PATH` environment variable that controls which directories are searched for binaries.
66+
4767
### Add Pelican binary to your `PATH` for the current terminal
4868

69+
To change the `PATH` variable for only the currently-running terminal session, execute the following line:
70+
4971
```bash
50-
$ cd pelican_Linux_x86_64 # Go to the binary folder
51-
$ export PATH="$PWD:$PATH" # Add current folder to the PATH
72+
export PATH="$HOME/.local/bin/:$PATH"
73+
```
74+
75+
Example outputs:
76+
77+
```bash
78+
$ export PATH="$HOME/.local/bin/:$PATH" # Add ~/.local/bin/ to the PATH
5279
$ pelican --version # Run Pelican binary
5380

54-
Version: 7.5.8
55-
Build Date: 2024-03-01T18:13:00Z
56-
Build Commit: d260a07d3b057d19b7fdd36125f91a8768531258
81+
Version: 7.12.0
82+
Build Date: 2025-01-14T21:33:23Z
83+
Build Commit: 57748c37af7574ec182e5a21db741c4c5a1e61a8
5784
Built By: goreleaser
5885
```
5986

6087
### Add Pelican binary to your `PATH` permanently
6188

89+
To add the `~/.local/bin/` directory to your `PATH` variable permanently, execute the following line (assuming you are using the 'bash' shell):
90+
91+
```bash
92+
echo "export PATH="\$HOME/.local/bin/:\$PATH" >> ~/.bashrc
93+
```
94+
95+
Example outputs:
96+
6297
```bash
63-
$ cd pelican_Linux_x86_64 # Go to the binary folder
64-
$ echo "export PATH=$PWD:\$PATH" >> ~/.bashrc # Add the current folder to your .bashrc file
98+
$ echo "export PATH=\$HOME/.local/bin:\$PATH" >> ~/.bashrc # Add the .local/bin folder to your .bashrc file
6599
$ source ~/.bashrc # Apply the change
66100
$ pelican --version # Run Pelican binary
67101
68-
Version: 7.5.8
69-
Build Date: 2024-03-01T18:13:00Z
70-
Build Commit: d260a07d3b057d19b7fdd36125f91a8768531258
102+
Version: 7.12.0
103+
Build Date: 2025-01-14T21:33:23Z
104+
Build Commit: 57748c37af7574ec182e5a21db741c4c5a1e61a8
71105
Built By: goreleaser
72106
```
73107

0 commit comments

Comments
 (0)