Mundarija:
2025 Muallif: John Day | [email protected]. Oxirgi o'zgartirilgan: 2025-01-13 06:58
Ushbu qo'llanmada men sizga PiHole statistikasi va Samba statistikasini ko'rsatadigan ko'rsatuvni qanday qilishni ko'rsataman.
Ta'minotlar
- 1x Raspberry Pi
- 1 ta Raspberry Pi displeyi
1 -qadam: Pihole -ni o'rnating
Pihole -ni o'rnatish uchun terminalni oching va quyidagi kodni kiriting. O'rnatishni davom ettiring va xohlaganingizcha o'rnating. Faqat parolni yozishni unutmang!
curl -sSL https://install.pi-hole.net https://install.pi-hole.net | bash
2 -qadam: Samba -ni o'rnating
Samba -ni o'rnatish va sozlash uchun terminalni oching va quyidagi kodni kiriting.
sudo apt-get samba samba-common-bin ni o'rnating
sudo mkdir -m 1777 /ulush
sudo leafpad /etc/samba/smb.conf
Keyin kodni tahrirlovchiga kiriting:
[pishare]
path =/share writeable = Ha niqob yarating = 0777 katalog niqobi = 0777 ommaviy = yo'q
Keyin foydalanuvchi yaratish uchun ushbu buyruqni bajaring va keyin foydalanuvchi uchun parolni kiriting:
sudo smbpasswd -pi
Nihoyat, ishga tushiring:
sudo systemctl smbd -ni qayta ishga tushiring
3 -qadam: Kodni o'rnating
Kodni sozlash uchun quyidagini bajaring:
wget https://raw.githubusercontent.com/barleybobs/piStats/master/setup.sh 2 Tabriklar vakili
Keyin ishga tushiring:
chmod +x setup.sh
Shundan so'ng, Fayl menejerini oching va /home /pi -ga o'ting va setup.sh faylini bosing va Terminalda ishga tushirish -ni tanlang. Bu kodni o'rnatadi va bog'liqliklarni yuklaydi.
4 -qadam: Avtomatik ishga tushirishni o'rnating
Endi biz pi -ni o'rnatamiz, u ishga tushganda displeyni to'liq ekran rejimida ochadi. Buni amalga oshirish uchun:
mkdir /home/pi/.config/autostart
nano /home/pi/.config/autostart/pistats.desktop
Keyin kiriting:
[Ish stoliga kirish]
Turi = Ilovaning nomi = PiStats Exec = bash -c 'sleep 1 && xterm -hold -fullscreen -hold -e "sudo python3 /home/pi/piStats/main.py" && uncluttered -idle 0.01 -root'
5 -qadam: Samba fayl serveriga ulaning
Fayl serveriga ulanish uchun File Explorer -ni oching va Kompyuter -ni tanlang, keyin tarmoq diskini xaritasini tanlang, so'ng papkaga qo'ying:
raspberrypi / pishare
6 -qadam: Pihole bilan bog'lanish
Pihole -ga ulanish uchun sizga DNS -ni o'zgartirish uchun ushbu foydali veb -saytdan foydalanishni maslahat beraman:
support.opendns.com/hc/en-us/articles/228007207-Windows-10- Konfiguratsiya