From nobody Sat Apr 16 11:59:09 2022 X-Original-To: freebsd-current@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 5D520C0E4DD for ; Sat, 16 Apr 2022 11:59:24 +0000 (UTC) (envelope-from grembo@freebsd.org) Received: from mail.evolve.de (mail.evolve.de [213.239.217.29]) (using TLSv1.3 with cipher TLS_CHACHA20_POLY1305_SHA256 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA512 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mail.evolve.de", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4KgWvb0z6tz4Tn2; Sat, 16 Apr 2022 11:59:22 +0000 (UTC) (envelope-from grembo@freebsd.org) Received: by mail.evolve.de (OpenSMTPD) with ESMTP id 6f46f9bd; Sat, 16 Apr 2022 11:59:14 +0000 (UTC) Received: by mail.evolve.de (OpenSMTPD) with ESMTPSA id bd0282a8 (TLSv1.3:AEAD-CHACHA20-POLY1305-SHA256:256:NO); Sat, 16 Apr 2022 11:59:11 +0000 (UTC) Content-Type: multipart/alternative; boundary=Apple-Mail-B5AB60DB-00BE-4FAC-8247-AABB091449C1 Content-Transfer-Encoding: 7bit List-Id: Discussions about the use of FreeBSD-current List-Archive: https://lists.freebsd.org/archives/freebsd-current List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-current@freebsd.org Mime-Version: 1.0 (1.0) Subject: Re: recover deleted file From: Michael Gmelin In-Reply-To: Date: Sat, 16 Apr 2022 13:59:09 +0200 Cc: Matthias Apitz , FreeBSD Current Message-Id: <70EA83C9-61AE-4256-9FF4-458197BA261D@freebsd.org> References: To: Sami Halabi X-Mailer: iPhone Mail (19D52) X-Rspamd-Queue-Id: 4KgWvb0z6tz4Tn2 X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=softfail (mx1.freebsd.org: 213.239.217.29 is neither permitted nor denied by domain of grembo@freebsd.org) smtp.mailfrom=grembo@freebsd.org X-Spamd-Result: default: False [-2.33 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; ARC_NA(0.00)[]; FREEFALL_USER(0.00)[grembo]; FROM_HAS_DN(0.00)[]; RCPT_COUNT_THREE(0.00)[3]; MV_CASE(0.50)[]; NEURAL_HAM_LONG(-0.98)[-0.980]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; DMARC_NA(0.00)[freebsd.org]; NEURAL_HAM_MEDIUM(-0.96)[-0.955]; R_SPF_SOFTFAIL(0.00)[~all]; RCVD_COUNT_THREE(0.00)[3]; TO_MATCH_ENVRCPT_SOME(0.00)[]; TO_DN_ALL(0.00)[]; NEURAL_HAM_SHORT(-0.79)[-0.790]; MLMMJ_DEST(0.00)[freebsd-current]; FREEMAIL_TO(0.00)[gmail.com]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+,1:+,2:~]; ASN(0.00)[asn:24940, ipnet:213.239.192.0/18, country:DE]; RCVD_TLS_ALL(0.00)[]; MID_RHS_MATCH_FROM(0.00)[] X-ThisMailContainsUnwantedMimeParts: N --Apple-Mail-B5AB60DB-00BE-4FAC-8247-AABB091449C1 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Depends on the kind of file. You can always: 1. reboot the system into single user mode, mount the fs readonly (important= to not overwrite data you want to recover) 2. dd the partition and into a file 3. find the content of the deleted file in the dump I was able to recover a complete codebase i deleted accidentally that way a l= ong time ago. Good luck Michael > On 16. Apr 2022, at 13:52, Sami Halabi wrote: >=20 > =EF=BB=BF > well.. thats the trivial answer.. the problem is backups is a day before..= . if i can undelete it would save me loss of 1 day offset.. >=20 > anyone? >=20 >> On Sat, Apr 16, 2022 at 2:49 PM Matthias Apitz wrote: >> El d=C3=ADa s=C3=A1bado, abril 16, 2022 a las 02:23:25 +0300, Sami Halabi= escribi=C3=B3: >>=20 >> > Hi, >> > is there anyway easy to restore deleted file by accident in UFS???? >>=20 >> Yes, restore it from a backup media. >>=20 >> matthias >>=20 >>=20 >> --=20 >> Matthias Apitz, =E2=9C=89 guru@unixarea.de, http://www.unixarea.de/ +49-1= 76-38902045 >> Public GnuPG key: http://www.unixarea.de/key.pub >>=20 >> Peace instead of NATO! =D0=9C=D0=B8=D1=80 =D0=B2=D0=BC=D0=B5=D1=81=D1=82= =D0=BE =D0=9D=D0=90=D0=A2=D0=9E! Frieden statt NATO! =C2=A1Paz en vez de OT= AN! >>=20 >=20 >=20 > --=20 > Sami Halabi > Information Systems Engineer > NMS Projects Expert, FreeBSD SysAdmin Expert > Asterisk Expert --Apple-Mail-B5AB60DB-00BE-4FAC-8247-AABB091449C1 Content-Type: text/html; charset=utf-8 Content-Transfer-Encoding: quoted-printable
Dep= ends on the kind of file.

Y= ou can always:
1. reboot the system into single user m= ode, mount the fs readonly (important to not overwrite data you want to reco= ver)
2. dd the partition and into a file
3. find the content of the deleted file in the dump

I was able to recover a complete codebase i= deleted accidentally that way a long time ago.

Good luck
Michael

On 16. Apr 2022, at 13:52, Sami Halabi &= lt;sodynet1@gmail.com> wrote:

=EF=BB=BF
well.. thats the trivial a= nswer.. the problem is backups is a day before... if i can undelete it would= save me loss of 1 day offset..

anyone?

On Sat, Apr 1= 6, 2022 at 2:49 PM Matthias Apitz <gu= ru@unixarea.de> wrote:
El d=C3=ADa s=C3=A1bado, abril 16, 2022 a las 02:23:25 +0300, Sa= mi Halabi escribi=C3=B3:

> Hi,
> is there anyway easy to restore deleted file by accident in UFS????
=
Yes, restore it from a backup media.

        matthias


--
Matthias Apitz, =E2=9C=89 guru@unixarea.de, http://www.unixarea.de/ +49-176-38902045
Public GnuPG key: http://www.unixarea.de/key.pub

Peace instead of NATO!  =D0=9C=D0=B8=D1=80 =D0=B2=D0=BC=D0=B5=D1=81=D1=82= =D0=BE =D0=9D=D0=90=D0=A2=D0=9E!  Frieden statt NATO! =C2=A1Paz en vez d= e OTAN!



--
Sami Halabi<= div>Information Systems Engineer
NMS Projects Expert, FreeBSD SysAdmin Expert
Asterisk E= xpert
= --Apple-Mail-B5AB60DB-00BE-4FAC-8247-AABB091449C1--