Subtitle: When your catβs food depends on debugging a microcomputer...
π± Recap from Day-27
In Day-27, we:
- Flashed Raspberry Pi OS (Lite) onto a microSD card
- Enabled SSH by adding a file to /boot
- (Optionally) added Wi-Fi credentials via wpa_supplicant.conf
- Inserted the SD card into the Raspberry Pi and powered it on
- Ran nmap to identify the Piβs IP β but couldnβt connect via SSH
π Table of Contents:
- β Confirming SSH Still Enabled
- π§ Checking Possible Issues
- π» Re-Insert & Recheck SD Card
- π Trying .local Hostname
- π Swapping Power & Boot Medium
- π§° Hardware Test: Running the Servo Script
- π Schedule with Cron
- β Final Status (Day-28)
π§ͺ Step-by-Step Troubleshooting
π 1. Confirming SSH Still Enabled
After scanning the network and identifying live hosts:
We attempted SSH But got:
π§ 2. Checking Possible Issues
π» 3. Re-Insert & Recheck SD Card
- Removed SD card
- Mounted it back on macOS
- Verified ssh file:
Output showed:
β SSH file still present
π 4. Trying .local Hostname:
But Fails β :
π Diagnosis: .local resolution (mDNS) not supported or not working on macOS without Bonjour or Avahi.
π 5. Swapping Power & Boot Medium:
Still not able to reach the Pi?
β Try this:
- Use another USB-C cable or power adapter
- Re-flash Raspberry Pi OS
This time, use Raspberry Pi Imager and make sure to:
- Enable SSH in the advanced options
- Set Wi-Fi SSID and password (if headless)
π§° 6. Hardware Test: Running the Servo Script:
After finally getting access:
You can now test your Python script that triggers the servo.
βοΈ Example: feed_cat.py
π 7. Schedule with Cron:
Do Crontab -e and Add:
π This runs the script every day at 8:00 AM.
β 8. Final Status (Day-28)
π Lessons Learned:
- Enabling SSH by file still works β just double-check the boot!
- mDNS can be flaky; nmap is your friend.
- Power supply really matters for Pi stability.
- Servo motors may need external power for consistent operation.
#30DaysLinuxChallenge #CloudWhisler
DevOps #Linux #RHCSA #Opensource #AWS #CloudComputing
Catch out by My LinkedIn profile
https://www.linkedin.com/in/rajpreet-gill-4569b4161/
Top comments (0)