mirror of
https://github.com/tiyn/wiki.git
synced 2025-12-18 14:29:45 +01:00
raspberry pi: setup and minor troubleshooting added
This commit is contained in:
@@ -23,7 +23,6 @@ Then the swap file can be changed using the following commands.
|
||||
`<location>` is the location of the swap file (for example `/swap.img`).
|
||||
`<size>` describes the new size of the swap file (for example `16G`)
|
||||
|
||||
|
||||
```sh
|
||||
swapoff <location>
|
||||
fallocate -l <size> <location>
|
||||
@@ -176,12 +175,25 @@ The following list shows some options to quickly clean up space.
|
||||
- [Package Mangers](/wiki/linux/package_manager.md)
|
||||
- [ViFM Trash Bin](/wiki/linux/vifm.md#empty-trash)
|
||||
|
||||
## Accessing Disks as User
|
||||
|
||||
Sometimes - for example when flashing an SD card for a
|
||||
[Raspberry Pi](/wiki/linux/raspberry_pi.md#setup) - it may be useful to do so with your default
|
||||
user and not using the root user.
|
||||
For this to work the user can be added to the `disk` group permanently.
|
||||
Please note that this however reduces the systems security.
|
||||
A command to do so, may look like the following (given the `$USER` variable is set correctly).
|
||||
|
||||
```sh
|
||||
usermod -a -G disk $USER
|
||||
```
|
||||
|
||||
## Error solving
|
||||
|
||||
This section addresses various problems that can occur and are related to
|
||||
disk-management.
|
||||
|
||||
### sudo: unable to open ... Read-only file system
|
||||
### `sudo: unable to open ... Read-only file system`
|
||||
|
||||
Ususally the filesystem will go into read-only mode whe the system is running
|
||||
and there is a consistency error.
|
||||
@@ -193,7 +205,7 @@ To fix it run:
|
||||
you may want to try using the ext4-specific fsck:
|
||||
- `fsck.ext4 -f /dev/sda1`
|
||||
|
||||
### cannot access: Transport endpoint is not connected
|
||||
### `cannot access: Transport endpoint is not connected`
|
||||
|
||||
This error message can occur if a mounted directory is left mounted due to a
|
||||
crash of the filesystem but not accessible anymore.
|
||||
|
||||
@@ -2,6 +2,29 @@
|
||||
|
||||
A [Rapberry Pi](https://www.raspberrypi.com) is a single board comuter.
|
||||
|
||||
## Setup
|
||||
|
||||
For setting up a classic Raspberry Pi an SD card is needed that contains the operating system.
|
||||
|
||||
For this an image has to be flashed.
|
||||
The images of the operating systems can be found on the
|
||||
[official website](https://www.raspberrypi.com/software/operating-systems).
|
||||
A command to flash may look similar to the following example, where `<img-path>` is the path to the
|
||||
image and `<disk-path>` is the path to the device to flash to (for example `/dev/sdb1`).
|
||||
|
||||
```sh
|
||||
dd if=<img-path> of=<disk-path> status=progress
|
||||
```
|
||||
|
||||
This however can also be done using the Raspberry Pi imager - which most
|
||||
[package managers](/wiki/linux/package_manager.md) package under `rpi-mager`.
|
||||
It too can also be found on the [official website](https://www.raspberrypi.com/software).
|
||||
When using the imager as a non-root user this user may have to be given rights to access disks or
|
||||
at least the SD card as described in the
|
||||
[corresponding article](/wiki/linux/disk-management.md#accessing-disks-as-user).
|
||||
|
||||
The setup using the imager is guided and easier.
|
||||
|
||||
## Hardware Additions
|
||||
|
||||
There are various hardware additions which can be used with the Raspberry Pi.
|
||||
|
||||
Reference in New Issue
Block a user