Structure needs cleaning error

General support for the Pi-Star System
Post Reply
kc2npz
Posts: 15
Joined: Thu Mar 21, 2019 9:28 pm

Structure needs cleaning error

Post by kc2npz »

hello,

Recently my pi-star has stopped allowing communications, and I had tried to restore to no success. when I try to update I get this error:


Update Running
Starting update, please wait...
Stopping Services...
Done
Updating DV Binaries...
fatal: bad default revision 'HEAD'
Updating /usr/local/bin...
fatal: No such ref: HEAD
From https://github.com/AndyTaylorTweet/Pi-Star_Binaries
* branch master -> FETCH_HEAD
error: unable to resolve reference HEAD: Structure needs cleaning
fatal: Cannot lock the ref 'HEAD'.
fatal: bad default revision 'HEAD'
Updates were not successfull, reverting to Pi-Star original files...
error: unable to create file YSFGateway (Structure needs cleaning)
fatal: Could not reset index file to revision 'origin/master'.
Done
Updating Pi-Star Binaries...
Updating /usr/local/sbin...
fatal: failed to read object 265a27217afdc5c883a7cd96ab5b69c263602bf4: Structure needs cleaning
fatal: The remote end hung up unexpectedly
Updates were not successfull, reverting to Pi-Star original files...
HEAD is now at a6d0e45 Update pistar-upgrade
Done
Updating Hostfiles...
Done
Updating Dashboard...
Updating /var/www/dashboard...
fatal: failed to read object 4949af6bf6134f9e0e721dddea56a0222a708f8a: Structure needs cleaning
fatal: The remote end hung up unexpectedly
Updates were not successfull, reverting to Pi-Star original files...
HEAD is now at c049662 Update configure.php
Done
Updating PiStar-Firewall...
Done
Starting Services...
Done
Updates complete, sleeping for a few seconds before making the disk Read-Only
Finished

Any help is appreciated
AF6VN
Posts: 821
Joined: Fri Jul 20, 2018 1:15 am

Re: Structure needs cleaning error

Post by AF6VN »

Google search seems to indicate possible file system corruption -- which for an SD card could mean it is near end-of-life. git reports the "unable to resolve" but the "structure needs" seems to be OS filesystem level.

However, I might consider trying git specific commands to see if there is garbage in the cache....

https://stackoverflow.com/questions/299 ... l-ref?rq=1

Failing that -- make a backup of settings, write a new SD card, restore settings to the new card, and try updating...

--
AF6VN
Dennis L Bieber
kc2npz
Posts: 15
Joined: Thu Mar 21, 2019 9:28 pm

Re: Structure needs cleaning error

Post by kc2npz »

Thanks, how do I know which version of the image to write to the new card?
AF6VN
Posts: 821
Joined: Fri Jul 20, 2018 1:15 am

Re: Structure needs cleaning error

Post by AF6VN »

kc2npz wrote: Sun Jul 28, 2019 12:54 pm Thanks, how do I know which version of the image to write to the new card?
So what version are you currently running... Hint -- look at the top line of the dashboard. You can probably ignore the minor version number and take the latest in the major version. Odds are, unless you went bleeding edge, you are running something in the 3.x series. The 4.x series is still beta release (though mandatory if you have an R-Pi 4B).

--
AF6VN
Dennis L Bieber
Post Reply