informatique:os:openwrt
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionLast revisionBoth sides next revision | ||
informatique:os:openwrt [2016/12/30 07:09] – [Configurer le rsyslog] pteu | informatique:os:openwrt [2023/01/29 12:59] – (dnsmasq) leases file in read-only pteu | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | [[https:// | + | [[https:// |
< | < | ||
+ | # exemple de sign-in banner : | ||
_______ | _______ | ||
| | ||
Line 36: | Line 37: | ||
Cliquer ensuite sur "Save & Apply", | Cliquer ensuite sur "Save & Apply", | ||
- | Pour que l'envoi de log soit pris en compte il faut redémarrer | + | ======UCI====== |
+ | |||
+ | **UCI** (Unified Configuration Interface) est la commande qui permet d' | ||
+ | |||
+ | On peut afficher la configuration sous plusieurs formats : | ||
+ | <code bash> | ||
+ | # format natif, programmable | ||
+ | uci show system | ||
+ | system.@system[0]=system | ||
+ | system.@system[0].cronloglevel=' | ||
+ | system.@system[0].zonename=' | ||
+ | system.@system[0].timezone=' | ||
+ | system.@system[0].hostname=' | ||
+ | |||
+ | # paramètre précis | ||
+ | uci get system.@system[0].zonename | ||
+ | Europe/ | ||
+ | |||
+ | # format lisible (human-readable) | ||
+ | uci export system | ||
+ | config system | ||
+ | option cronloglevel ' | ||
+ | option zonename ' | ||
+ | option timezone ' | ||
+ | option hostname ' | ||
+ | </ | ||
+ | |||
+ | '' | ||
+ | |||
+ | Exemple de création d'une nouvelle section : | ||
+ | <code bash> | ||
+ | uci show sectionperso | ||
+ | uci import sectionperso < /dev/null | ||
+ | uci set sectionperso.myname=masectionperso | ||
+ | uci add sectionperso blah | ||
+ | uci commit | ||
+ | uci show sectionperso | ||
+ | sectionperso.@blah[0]=blah | ||
+ | </ | ||
+ | |||
+ | =====UCI extras===== | ||
+ | |||
+ | Pour éviter les erreurs de configuration, | ||
+ | <code bash> | ||
+ | opkg update | ||
+ | opkg install diffutils | ||
+ | uclient-fetch -O uci-extras.sh " | ||
+ | . ./ | ||
+ | </ | ||
+ | |||
+ | Cela permet d'ajouter les commandes '' | ||
+ | |||
+ | <code bash> | ||
+ | uci validate | ||
+ | uci diff dhcp | ||
+ | </ | ||
+ | |||
+ | =====Liens utiles===== | ||
+ | |||
+ | * https:// | ||
+ | |||
+ | |||
+ | ======Problèmes====== | ||
+ | |||
+ | =====(dnsmasq) leases file in read-only===== | ||
+ | |||
+ | <code bash> | ||
+ | dnsmasq[1]: cannot open or create lease file / | ||
+ | </ | ||
+ | [[https:// | ||
+ | <code bash> | ||
+ | touch / | ||
+ | uci set dhcp.@dnsmasq[0].leasefile='/ | ||
+ | service dnsmasq restart | ||
+ | </ | ||
+ |
informatique/os/openwrt.txt · Last modified: 2023/02/08 10:35 by pteu