* [9fans] What happens to deleted files in 9front
@ 2026-01-28 15:09 rc.upcsa
2026-01-28 15:57 ` hahahahacker2009
` (4 more replies)
0 siblings, 5 replies; 10+ messages in thread
From: rc.upcsa @ 2026-01-28 15:09 UTC (permalink / raw)
To: 9fans
[-- Attachment #1: Type: text/plain, Size: 431 bytes --]
Hi all,
When a file is removed in 9front using rm, I take it that it is altogether deleted and non-recoverable. In Linux one can sometimes use specialised tools to recover files removed with rm.
------------------------------------------
9fans: 9fans
Permalink: https://9fans.topicbox.com/groups/9fans/T0c7edd96d131231e-M9d8d0477da58280cdab67f62
Delivery options: https://9fans.topicbox.com/groups/9fans/subscription
[-- Attachment #2: Type: text/html, Size: 983 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [9fans] What happens to deleted files in 9front
2026-01-28 15:09 [9fans] What happens to deleted files in 9front rc.upcsa
@ 2026-01-28 15:57 ` hahahahacker2009
2026-01-28 16:23 ` Noam Preil
2026-01-28 16:22 ` ori
` (3 subsequent siblings)
4 siblings, 1 reply; 10+ messages in thread
From: hahahahacker2009 @ 2026-01-28 15:57 UTC (permalink / raw)
To: 9fans
> Hi all,
> When a file is removed in 9front using rm, I take it that it is altogether deleted and non-recoverable. In Linux one can sometimes use specialised tools to recover files removed with rm.
>
Why do you think that 9front will make it unrecoverable?
I haven't heard of any os that tries to make the file unrecoverable
when removed (e.g by zeroing it, or ``shred'')
>
------------------------------------------
9fans: 9fans
Permalink: https://9fans.topicbox.com/groups/9fans/T0c7edd96d131231e-M9238570381ad21329df61af2
Delivery options: https://9fans.topicbox.com/groups/9fans/subscription
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [9fans] What happens to deleted files in 9front
2026-01-28 15:09 [9fans] What happens to deleted files in 9front rc.upcsa
2026-01-28 15:57 ` hahahahacker2009
@ 2026-01-28 16:22 ` ori
2026-01-28 16:28 ` cinap_lenrek
` (2 subsequent siblings)
4 siblings, 0 replies; 10+ messages in thread
From: ori @ 2026-01-28 16:22 UTC (permalink / raw)
To: 9fans
Quoth rc.upcsa@gmail.com:
> Hi all,
> When a file is removed in 9front using rm, I take it that it is altogether deleted and non-recoverable. In Linux one can sometimes use specialised tools to recover files removed with rm.
>
well, on gefs, this happens:
/sys/src/cmd/gefs/fs.c:1944: fsremove(Fmsg *m, int id, Amsg **ao)
on hjfs, this happens:
/sys/src/cmd/hjfs/fs1.c:923: delete(Fs *fs, FLoc *l, Buf *b)
and on cwfs, this happens:
/sys/src/cmd/cwfs/9p2.c:1303: doremove(File *f)
if your goal is to un-delete a file, you can run '9fs dump'
and get old revisions:
% 9fs dump
% ls /n/dump
/n/dump/adm@day.2025.04.30_02:10:49
/n/dump/adm@day.2025.04.30_08:21:24
/n/dump/adm@day.2025.05.03_02:05:56
<snip>
/n/dump/main@minute.2026.01.27_03:41:01
/n/dump/main@minute.2026.01.27_03:42:01
/n/dump/main@minute.2026.01.27_03:43:01
gefs takes snapshots once a minute, deleting old ones;
cwfs does them nightly; I don't remember what hjfs does,
but I think it depends on cron.
------------------------------------------
9fans: 9fans
Permalink: https://9fans.topicbox.com/groups/9fans/T0c7edd96d131231e-M37ae25be8965a44df1c0ab34
Delivery options: https://9fans.topicbox.com/groups/9fans/subscription
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [9fans] What happens to deleted files in 9front
2026-01-28 15:57 ` hahahahacker2009
@ 2026-01-28 16:23 ` Noam Preil
0 siblings, 0 replies; 10+ messages in thread
From: Noam Preil @ 2026-01-28 16:23 UTC (permalink / raw)
To: 9fans
[-- Attachment #1: Type: text/plain, Size: 759 bytes --]
If you know some of the contents of the file you can grep the storage device for it and maybe find the rest. It's useful for recovery by keyword in every system, at least for small files.
Some Linux tools would work fine if applied to a 9front drive too, since they work by scanning the block device for file signatures (e.g. image headers that say "this is a jpg") and those ll be the same on both.
The one exception would be venti/fossil but if you were using that you wouldn't be asking how to recover deleted files, so.
------------------------------------------
9fans: 9fans
Permalink: https://9fans.topicbox.com/groups/9fans/T0c7edd96d131231e-M7d19a96dd267124fdc659c75
Delivery options: https://9fans.topicbox.com/groups/9fans/subscription
[-- Attachment #2: Type: text/html, Size: 1528 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [9fans] What happens to deleted files in 9front
2026-01-28 15:09 [9fans] What happens to deleted files in 9front rc.upcsa
2026-01-28 15:57 ` hahahahacker2009
2026-01-28 16:22 ` ori
@ 2026-01-28 16:28 ` cinap_lenrek
2026-01-28 19:01 ` Stuart Morrow
2026-01-29 3:46 ` ron minnich
4 siblings, 0 replies; 10+ messages in thread
From: cinap_lenrek @ 2026-01-28 16:28 UTC (permalink / raw)
To: 9fans
Plan9 file-systems provide periodic snapshots.
9fs dump
ls /n/dump
So recoverying a deleted file can be as easy as:
cp /n/dump/YYYY/MMDD/path/to/file ...
See also: history(1)
The frequency and time of the snapshots depends
on the file-system being in use.
--
cinap
------------------------------------------
9fans: 9fans
Permalink: https://9fans.topicbox.com/groups/9fans/T0c7edd96d131231e-Mf04a0f4b9edb9e67ad034d34
Delivery options: https://9fans.topicbox.com/groups/9fans/subscription
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [9fans] What happens to deleted files in 9front
2026-01-28 15:09 [9fans] What happens to deleted files in 9front rc.upcsa
` (2 preceding siblings ...)
2026-01-28 16:28 ` cinap_lenrek
@ 2026-01-28 19:01 ` Stuart Morrow
2026-01-28 23:14 ` Charles Forsyth
2026-01-29 3:46 ` ron minnich
4 siblings, 1 reply; 10+ messages in thread
From: Stuart Morrow @ 2026-01-28 19:01 UTC (permalink / raw)
To: 9fans
> When a file is removed in 9front using rm, I take it that it is altogether deleted and non-recoverable. In Linux one can sometimes use specialised tools to recover files removed with rm.
It's not clear to me what exactly you're asking. The last sentence
seems to narrow it down, but in fact doesn't, because you might be
referring to the 'cat /proc/.../fd' method on a living process that
still has the file.
"Filesystem filesystems" on Plan 9 mimic Unix's "unlink, not delete" behaviour.
------------------------------------------
9fans: 9fans
Permalink: https://9fans.topicbox.com/groups/9fans/T0c7edd96d131231e-Mb2cc275712b7caf4044b018d
Delivery options: https://9fans.topicbox.com/groups/9fans/subscription
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [9fans] What happens to deleted files in 9front
2026-01-28 19:01 ` Stuart Morrow
@ 2026-01-28 23:14 ` Charles Forsyth
2026-01-28 23:26 ` Charles Forsyth
0 siblings, 1 reply; 10+ messages in thread
From: Charles Forsyth @ 2026-01-28 23:14 UTC (permalink / raw)
To: 9fans
[-- Attachment #1: Type: text/plain, Size: 1165 bytes --]
> "Filesystem filesystems" on Plan 9 mimic Unix's "unlink, not delete"
> behaviour.
venti/fossil doesn't, and it's not a requirement.
h% file blimp
blimp: cannot open: 'blimp' file does not exist
h% echo still here >blimp
h% {sleep 10; cat}<blimp&
h% rm blimp
h% cat: error reading <stdin>: file has been removed
On Wed, 28 Jan 2026 at 20:42, Stuart Morrow <morrow.stuart@gmail.com> wrote:
> > When a file is removed in 9front using rm, I take it that it is
> altogether deleted and non-recoverable. In Linux one can sometimes use
> specialised tools to recover files removed with rm.
>
> It's not clear to me what exactly you're asking. The last sentence
> seems to narrow it down, but in fact doesn't, because you might be
> referring to the 'cat /proc/.../fd' method on a living process that
> still has the file.
>
> "Filesystem filesystems" on Plan 9 mimic Unix's "unlink, not delete"
> behaviour.
------------------------------------------
9fans: 9fans
Permalink: https://9fans.topicbox.com/groups/9fans/T0c7edd96d131231e-M92e66eea41a2c70b81e7915d
Delivery options: https://9fans.topicbox.com/groups/9fans/subscription
[-- Attachment #2: Type: text/html, Size: 2759 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [9fans] What happens to deleted files in 9front
2026-01-28 23:14 ` Charles Forsyth
@ 2026-01-28 23:26 ` Charles Forsyth
0 siblings, 0 replies; 10+ messages in thread
From: Charles Forsyth @ 2026-01-28 23:26 UTC (permalink / raw)
To: 9fans
[-- Attachment #1: Type: text/plain, Size: 1594 bytes --]
it works in traditional Unix because files are really i-nodes and
the directories refer to them, but
even if the count is zero, they survive until a separately
reference-counted in-memory copy made by iget loses its final open-file
reference.
unless the system crashes before that event. oh no!
On Wed, 28 Jan 2026 at 23:14, Charles Forsyth <charles.forsyth@gmail.com>
wrote:
>
> "Filesystem filesystems" on Plan 9 mimic Unix's "unlink, not delete"
>> behaviour.
>
>
> venti/fossil doesn't, and it's not a requirement.
>
> h% file blimp
> blimp: cannot open: 'blimp' file does not exist
> h% echo still here >blimp
> h% {sleep 10; cat}<blimp&
> h% rm blimp
> h% cat: error reading <stdin>: file has been removed
>
> On Wed, 28 Jan 2026 at 20:42, Stuart Morrow <morrow.stuart@gmail.com>
> wrote:
>
>> > When a file is removed in 9front using rm, I take it that it is
>> altogether deleted and non-recoverable. In Linux one can sometimes use
>> specialised tools to recover files removed with rm.
>>
>> It's not clear to me what exactly you're asking. The last sentence
>> seems to narrow it down, but in fact doesn't, because you might be
>> referring to the 'cat /proc/.../fd' method on a living process that
>> still has the file.
>>
>> "Filesystem filesystems" on Plan 9 mimic Unix's "unlink, not delete"
>> behaviour.
------------------------------------------
9fans: 9fans
Permalink: https://9fans.topicbox.com/groups/9fans/T0c7edd96d131231e-Mc6e6bb88ee967e0b6c119947
Delivery options: https://9fans.topicbox.com/groups/9fans/subscription
[-- Attachment #2: Type: text/html, Size: 3482 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [9fans] What happens to deleted files in 9front
2026-01-28 15:09 [9fans] What happens to deleted files in 9front rc.upcsa
` (3 preceding siblings ...)
2026-01-28 19:01 ` Stuart Morrow
@ 2026-01-29 3:46 ` ron minnich
2026-01-29 8:05 ` rc.upcsa
4 siblings, 1 reply; 10+ messages in thread
From: ron minnich @ 2026-01-29 3:46 UTC (permalink / raw)
To: 9fans
[-- Attachment #1: Type: text/plain, Size: 1367 bytes --]
I can not figure out what led you to conclude that files are deleted and
unrecoverable, ever. Are you using 9front or just reading documents?
Here's a useful one:
http://man.9front.org/1/yesterday
which has been around for, I guess, nearly 40 years?
But no, it's very very hard to lose a file in any version of Plan 9.
Going to systems like Linux is very depressing that way. It always feels
strange to me to be on any Unix system and realize files can be lost
irrevocably.
On Wed, Jan 28, 2026 at 7:42 AM <rc.upcsa@gmail.com> wrote:
> Hi all,
> When a file is removed in 9front using rm, I take it that it is altogether
> deleted and non-recoverable. In Linux one can sometimes use specialised
> tools to recover files removed with rm.
>
>
>
> *9fans <https://9fans.topicbox.com/latest>* / 9fans / see discussions
> <https://9fans.topicbox.com/groups/9fans> + participants
> <https://9fans.topicbox.com/groups/9fans/members> + delivery options
> <https://9fans.topicbox.com/groups/9fans/subscription> Permalink
> <https://9fans.topicbox.com/groups/9fans/T0c7edd96d131231e-M9d8d0477da58280cdab67f62>
>
------------------------------------------
9fans: 9fans
Permalink: https://9fans.topicbox.com/groups/9fans/T0c7edd96d131231e-M269e092bc42a1544090cc1b0
Delivery options: https://9fans.topicbox.com/groups/9fans/subscription
[-- Attachment #2: Type: text/html, Size: 2054 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [9fans] What happens to deleted files in 9front
2026-01-29 3:46 ` ron minnich
@ 2026-01-29 8:05 ` rc.upcsa
0 siblings, 0 replies; 10+ messages in thread
From: rc.upcsa @ 2026-01-29 8:05 UTC (permalink / raw)
To: 9fans
[-- Attachment #1: Type: text/plain, Size: 717 bytes --]
Thanks all, this clears it up.
Just to be clear: I was not assuming 9front tries to make files unrecoverable. My question was really whether rm means "gone for good" in practice, compared with Linux where recovery tools are sometimes used.
The short answer seems to be: files are not deliberately shredded, and it's actually harder to lose data permanently on Plan 9 than on typical Linux setups.
I appreciate all the explanations, and I'll give some of the suggestions a try.
------------------------------------------
9fans: 9fans
Permalink: https://9fans.topicbox.com/groups/9fans/T0c7edd96d131231e-Md36f05f64b1dabb419de62c7
Delivery options: https://9fans.topicbox.com/groups/9fans/subscription
[-- Attachment #2: Type: text/html, Size: 1338 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread
end of thread, other threads:[~2026-01-29 8:25 UTC | newest]
Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-01-28 15:09 [9fans] What happens to deleted files in 9front rc.upcsa
2026-01-28 15:57 ` hahahahacker2009
2026-01-28 16:23 ` Noam Preil
2026-01-28 16:22 ` ori
2026-01-28 16:28 ` cinap_lenrek
2026-01-28 19:01 ` Stuart Morrow
2026-01-28 23:14 ` Charles Forsyth
2026-01-28 23:26 ` Charles Forsyth
2026-01-29 3:46 ` ron minnich
2026-01-29 8:05 ` rc.upcsa
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).