Add content from #8174

This commit is contained in:
Fabian Affolter 2019-02-15 09:44:21 +01:00
parent cb6ae96b5b
commit d3160f40ad
No known key found for this signature in database
GPG Key ID: E23CD2DD36A4397F

View File

@ -116,3 +116,37 @@ The example above, creates the following sensors:
- sensor.asuswrt_download_speed (unit_of_measurement: Mbit/s)
- sensor.asuswrt_upload (unit_of_measurement: Gigabyte - *Daily accumulation*)
- sensor.asuswrt_upload_speed (unit_of_measurement: Mbit/s)
## {% linkable_title Padavan custom firmware (The rt-n56u project) %}
The [rt-n56u project](https://bitbucket.org/padavan/rt-n56u) does not store `dnsmasq.leases` which is used to track devices at `/var/lib/misc/` as `asuswrt` do. However this component can still be used for the rt-n56u project by linking `dnsmasq.leases` during the boot process of the router.
Follow these steps to setup the link.
1. SSH or Telnet into the router. (default ssh admin@my.router)
2. Run the following command to find the file:
```bash
$ find / -name "dnsmasq.leases"
```
3. Copy or remember the full path of, example: `/tmp/dnsmasq.leases`
4. Create the folder if it does not exist:
```bash
$ mkdir -p /var/lib/misc
```
5. Add the linking process to the routers started script (one line):
```bash
$ echo "/bin/ln -s /tmp/dnsmasq.leases /var/lib/misc/dnsmasq.leases" >> /etc/storage/started_script.sh
```
6. Reboot the router or link the file:
```bash
$ /bin/ln -s /tmp/dnsmasq.leases /var/lib/misc/dnsmasq.leases
```
The started script is also accessible and editable in the Router's web interface. `Advanced Settings -> Customization -> Scripts -> Custom User Script -> Run After Router Started`