2

If I make a dotted directory in / Raspbian removes it on reboot, however symbolic links and regular files are unaffected. Why?

The problem occurred when I tried to use git to version control my configuration: Raspbian removes .git from /

Update: When I wrote this question I did not suspect to get answers like use

ls -a

So to clarify: I use CLI on daily basis, and of course I use the -a switch for ls to list dotted files.

Funny but I cannot reproduce this error on the other pi in the office. The only notable difference that the malfuctioning pi has a Cirrus Logic audio card attached to it, but it has the same kernel. I've not yet installed my cross-compiled kernel and modules.

  • You may have already seen this, but Find which process is modifying a file over at unix.se (and the linked Qs from there) may help you track down what's deleting it (so long as you can start the logging early enough in boot). – Chris H Jul 27 '16 at 12:55
1

Malfunction?

I can't replicate this on a fresh 2016-03-18-rasbian-jessie install on an original Raspberry Pi B:

pi@raspberrypi:~ $ ls -a /
.   bin   dev  home  lost+found  mnt  proc  run   srv  tmp  var
..  boot  etc  lib   media       opt  root  sbin  sys  usr
pi@raspberrypi:~ $ sudo mkdir /.git
pi@raspberrypi:~ $ ls -a /
.   bin   dev  .git  lib         media  opt   root  sbin  sys  usr
..  boot  etc  home  lost+found  mnt    proc  run   srv   tmp  var
pi@raspberrypi:~ $ sudo reboot
Connection to 192.168.1.172 closed by remote host.
Connection to 192.168.1.172 closed.
hydraxan@bubblepop-rpi ~ $ ssh pi@192.168.1.172
pi@192.168.1.172's password:

The programs included with the Debian GNU/Linux system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.

Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
permitted by applicable law.
Last login: Thu May  5 05:03:21 2016
pi@raspberrypi:~ $ ls -a /
.   bin   dev  .git  lib         media  opt   root  sbin  sys  usr
..  boot  etc  home  lost+found  mnt    proc  run   srv   tmp  var
pi@raspberrypi:~ $
  • It must be when I tried again, it left the directory, but corrupted the inode metadata. – atevm May 6 '16 at 15:32
1

Raspbian does not remove dotted directories, it does however, hide them in normal directory listings and in the default GUI file manager listing. You can view these directories from the command line using the -a (all ) flag to the ls command:

ls -la /

From the graphical file manager you can select Show Hidden from the View Menu, or via the keyboard shortcut:

ctrl-H.

  • I know that -a switch for ls. – atevm Apr 28 '16 at 7:24

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.