On Fri, Nov 18, 2016 at 05:56:20AM +1000, Stuart Longland wrote:
> On 18/11/16 05:51, Peter N. M. Hansteen wrote:
> > This is probably a one-off (actually two, but more about that later) that
> will only ever bite me and never be heard of againg, but I have to ask:
> >
> > What could cause your /dev/, which is normally in the kilobytes in size, to
> swell to *gigabyte* range?
> 
> Very stupid question, but your /dev/null wouldn't have been replaced by
> a plain file would it?
> 
> (Yes, I had that happen to me by accident once.)

Not stupid at all to my mind, but

[Thu Nov 17 20:58:34] peter@skapet:~$ ls -l /dev/null
crw-rw-rw-  1 root  wheel    2,   2 Nov 17 20:58 /dev/null

so that does not seem to be the problem.

however 

[Thu Nov 17 21:00:39] peter@skapet:~$ doas ls -lS /dev/ | head
total 2301984
-rw-r--r--  1 root   wheel       1178386432 Oct 27  2015 sd0
-r-xr-xr-x  1 root   wheel            11584 Nov 17 07:36 MAKEDEV
dr-xr-xr-x  2 root   wheel             1024 Nov 17 18:01 fd
lrwxr-xr-x  1 root   wheel                9 Aug  1  2014 audioctl -> audioctl0
lrwxr-xr-x  1 root   wheel                6 Aug  1  2014 audio -> audio0
lrwxr-xr-x  1 root   wheel                6 Aug  1  2014 mixer -> mixer0
lrwxr-xr-x  1 root   wheel                6 Aug  1  2014 radio -> radio0
lrwxr-xr-x  1 root   wheel                6 Aug  1  2014 sound -> sound0
lrwxr-xr-x  1 root   wheel                6 Aug  1  2014 video -> video0
[Thu Nov 17 21:00:49] peter@skapet:~$ 

and 

[Thu Nov 17 21:01:34] peter@skapet:~$ file /dev/sd0
/dev/sd0: ISO 9660 CD-ROM filesystem data 'Ubuntu 15.10 amd64             ' 
(bootable) x86 boot sector; partition 2: ID=0xef, starthead 254, startsector 
2279532, 4544 sectors

so a device had indeed been replaced by a regular file.

Simple PEBKAC caused this then.

-- 
Peter N. M. Hansteen, member of the first RFC 1149 implementation team
http://bsdly.blogspot.com/ http://www.bsdly.net/ http://www.nuug.no/
"Remember to set the evil bit on all malicious network traffic"
delilah spamd[29949]: 85.152.224.147: disconnected after 42673 seconds.

Reply via email to