testdisk_static on QNAP total Linux novice Topic is solved

How to use TestDisk to recover lost partition
Forum rules
When asking for technical support:
- Search for posts on the same topic before posting a new question.
- Give clear, specific information in the title of your post.
- Include as many details as you can, MOST POSTS WILL GET ONLY ONE OR TWO ANSWERS.
- Post a follow up with a "Thank you" or "This worked!"
- When you learn something, use that knowledge to HELP ANOTHER USER LATER.
Before posting, please read https://www.cgsecurity.org/testdisk.pdf
Locked
Message
Author
JWvanLohuizen
Posts: 7
Joined: 05 Jun 2020, 23:20

testdisk_static on QNAP total Linux novice

#1 Post by JWvanLohuizen »

I am 60 and have been into computers on and off as an enthusiast since 11th grade. I went from basic to a couple others to ms-dos then win 3.0. I
then hacked one tiny utility and rapidly moved to gui's. Coding ended with brain disorder but excelled well between coders and users.

I now have 2 QNAP servers and in my haste of moving my old tv shows and documentaries, I fell in my safety net at the wrong time (part of the brain disorder that has this year been identified and not quite well treated due to CVD-19),believing I was deleting the old (server folders (partition), followed by the recycle bin.

I briefly got a name drop there to have one technician use putty to locate my external drive and start testdisk_static.

I needed a new internet modem and despite telling Spectrum tech not to touch my router at the end of a long session he tapped the restart and putty closed aborting Testdisk. 2.5 hours on hold to QNAP and I finally, despite huge protest, was shown the code to log in and open the folder. Then my external raid died! Now I finally got it all up and have only gotten to a Permission Denied.

My entire effort is below. Some code copy and pasted from examples.

A Windows 7 x64 Forever, point and click user and possibly future Ubuntu user.


Please Help,

Jan-Willem vanLohuizen

Using username "admin".
admin@10.0.0.177's password:
[~] # cd /share/external/DEV3303_1/Test-Disk (I renamed for easier typing; hand issues so I use virtual keyboard and mouse slowly)
[/share/external/DEV3303_1/Test-Disk] # sudo testdisk_static
sudo: testdisk_static: command not found
[/share/external/DEV3303_1/Test-Disk] # sudo ./testdisk_static
sudo: ./testdisk_static: command not found
[/share/external/DEV3303_1/Test-Disk] # ./testdisk_static
-sh: ./testdisk_static: Permission denied
[/share/external/DEV3303_1/Test-Disk] # ls -l testdisk_static
-rw-rw-rw- 1 JWvL-MSI-PC everyone 8605296 2020-06-01 08:29 testdisk_static
[/share/external/DEV3303_1/Test-Disk] # su - ./testdisk_static
-sh: su: command not found
[/share/external/DEV3303_1/Test-Disk] # su ./testdisk_static
-sh: su: command not found
[/share/external/DEV3303_1/Test-Disk] # run su - ./testdisk_static
-sh: run: command not found
[/share/external/DEV3303_1/Test-Disk] # su JWvL-MSI-PC ./testdisk_static
-sh: su: command not found
[/share/external/DEV3303_1/Test-Disk] # ./testdisk_static
-sh: ./testdisk_static: Permission denied
[/share/external/DEV3303_1/Test-Disk] # ./testdisk_static
-sh: ./testdisk_static: Permission denied
[/share/external/DEV3303_1/Test-Disk] #
[/share/external/DEV3303_1/Test-Disk] # admin ./testdisk_static
-sh: admin: command not found
[/share/external/DEV3303_1/Test-Disk] # sudo admin ./testdisk_static
sudo: admin: command not found
[/share/external/DEV3303_1/Test-Disk] # su admin ./testdisk_static
-sh: su: command not found
[/share/external/DEV3303_1/Test-Disk] # ./testdisk_static password-edited-out
-sh: ./testdisk_static: Permission denied
[/share/external/DEV3303_1/Test-Disk] #
[/share/external/DEV3303_1/Test-Disk] # ./testdisk_static password-edited-out
-sh: ./testdisk_static: Permission denied
[/share/external/DEV3303_1/Test-Disk] # cd ./testdisk_static
-sh: cd: ./testdisk_static: Not a directory
[/share/external/DEV3303_1/Test-Disk] # password-edited-out ./testdisk_static
-sh: ~9a1s8d2f7g3h6j4k5L^+: command not found
[/share/external/DEV3303_1/Test-Disk] # ./testdisk_static JWvL-MSI-PC password-edited-out
-sh: ./testdisk_static: Permission denied
[/share/external/DEV3303_1/Test-Disk] # TestDisk
-sh: TestDisk: command not found
[/share/external/DEV3303_1/Test-Disk] # Using username "admin".
sudo: testdisk_static: command not found
[/share/external/DEV3303_1/Test-Disk] # sudo ./testdisk_static
sudo: ./testdisk_static: command not found
[/share/external/DEV3303_1/Test-Disk] # ./testdisk_static
-sh: ./testdisk_static: Permission denied
[/share/external/DEV3303_1/Test-Disk] # ls -l testdisk_static
-rw-rw-rw- 1 JWvL-MSI-PC everyone 8605296 2020-06-01 08:29 testdisk_static
[/share/external/DEV3303_1/Test-Disk] # su - ./testdisk_static
-sh: su: command not found
[/share/external/DEV3303_1/Test-Disk] # su ./testdisk_static
-sh: su: command not found
[/share/external/DEV3303_1/Test-Disk] # run su - ./testdisk_static
-sh: run: command not found
[/share/external/DEV3303_1/Test-Disk] # su JWvL-MSI-PC ./testdisk_static
-sh: su: command not found
[/share/external/DEV3303_1/Test-Disk] # ./testdisk_static
-sh: ./testdisk_static: Permission denied
[/share/external/-sh: Using: command not found
DEV3303_1/Test-Disk] # ./testdisk_static
-sh: ./testdisk_static: Permission denied
[/share/external/DEV3303_1/Test-Disk] #
[/share/external/DEV3303_1/Test-Disk] # admin ./testdisk_static
-sh: admin: command not found
[/share/external/DEV3303_1/Test-Disk] # sudo admin ./testdisk_static
sudo: admin: command not found
[/share/external/DEV3303_1/Test-Disk] # su admin ./testdisk_static
-sh: su: command not found
[/share/external/DEV3303_1/Test-Disk] # ./testdisk_static password-edited-out
[/share/external/DEV3303_1/Test-Disk] # admin@10.0.0.177's password:
> [~] # cd /share/external/DEV3303_1/Test-Disk
> [/share/external/DEV3303_1/Test-Disk] # sudo testdisk_static
> sudo: testdisk_static: command not found
> [/share/external/DEV3303_1/Test-Disk] # sudo ./testdisk_static
> sudo: ./testdisk_static: command not found
> [/share/external/DEV3303_1/Test-Disk] # ./testdisk_static
> -sh: ./testdisk_static: Permission denied
> [/share/external/DEV3303_1/Test-Disk] # ls -l testdisk_static
> -rw-rw-rw- 1 JWvL-MSI-PC everyone 8605296 2020-06-01 08:29 testdisk_static
> [/share/external/DEV3303_1/Test-Disk] # su - ./testdisk_static
> -sh: su: command not found
> [/share/external/DEV3303_1/Test-Disk] # su ./testdisk_static
> -sh: su: command not found
> [/share/external/DEV3303_1/Test-Disk] # run su - ./testdisk_static
> -sh: run: command not found
> [/share/external/DEV3303_1/Test-Disk] # su JWvL-MSI-PC ./testdisk_static
> -sh: su: command not found
> [/share/external/DEV3303_1/Test-Disk] # ./testdisk_static
> -sh: ./testdisk_static: Permission denied
> [/share/external/DEV3303_1/Test-Disk] # ./testdisk_static
> -sh: ./testdisk_static: Permission denied
> [/share/external/DEV3303_1/Test-Disk] #
> [/share/external/DEV3303_1/Test-Disk] # admin ./testdisk_static
> -sh: admin: command not found
> [/share/external/DEV3303_1/Test-Disk] # sudo admin ./testdisk_static
> sudo: admin: command not found
> [/share/external/DEV3303_1/Test-Disk] # su admin ./testdisk_static
> -sh: su: command not found
> [/share/external/DEV3303_1/Test-Disk] # ./testdisk_static password-edited-out+
> -sh: ./testdisk_static: Permission denied
> [/share/external/DEV3303_1/Test-Disk] #
> [/share/external/DEV3303_1/Test-Disk] # ./testdisk_static password-edited-out
> -sh: ./testdisk_static: Permission denied
> [/share/external/DEV3303_1/Test-Disk] # cd ./testdisk_static
> -sh: cd: ./testdisk_static: Not a directory
> [/share/external/DEV3303_1/Test-Disk] # password-edited-out ./testdisk_static
> -sh: ~9a1s8d2f7g3h6j4k5L^+: command not found
> [/share/external/DEV3303_1/Test-Disk] # ./testdisk_static JWvL-MSI-PC password-edited-out
> -sh: ./testdisk_static: Permission denied
>

User avatar
cgrenier
Site Admin
Posts: 5432
Joined: 18 Feb 2012, 15:08
Location: Le Perreux Sur Marne, France
Contact:

Re: testdisk_static on QNAP total Linux novice

#2 Post by cgrenier »

As you are already root, no need to use su or sudo.
Use 'ls ' to list the content of the current directory.
To run testdik_static in the local directory, use './testdisk_static'.
External disk may be mounted as "noexec" (no execution), it can explain the "Permission denied" error.
A workaround is to copy the testdisk directory:

Code: Select all

cp -r /share/external/DEV3303_1/Test-Disk /tmp
cd /tmp/Test-Disk
ls
./testdisk_static

JWvanLohuizen
Posts: 7
Joined: 05 Jun 2020, 23:20

Re: testdisk_static on QNAP total Linux novice

#3 Post by JWvanLohuizen »

Thank You for the personal response CG.

I am in the middle of some life things.

Thanks for the quick response I will try this in a few minutes.

Jan-Willem

JWvanLohuizen
Posts: 7
Joined: 05 Jun 2020, 23:20

Re: testdisk_static on QNAP total Linux novice

#4 Post by JWvanLohuizen »

This is the result that I got:
login as: admin
admin@10.0.0.177's password:
[~] # cp -r /share/external/DEV3303_1/Test-Disk /tmp
[~] # cd /tmp/Test-Disk
[/tmp/Test-Disk] # ls
AUTHORS fidentify_static NEWS readme.txt
ChangeLog icons/ photorec.8 testdisk.8
COPYING INFO photorec_static testdisk_static
documentation.html jni/ README_dev_photorec.txt THANKS
fidentify.8 l/ README.md VERSION
[/tmp/Test-Disk] # ./testdisk_static
-sh: ./testdisk_static: Permission denied
[/tmp/Test-Disk] #
Still Permission denied

I can say that I have used this successfully myself with Window 7 and it was running on this server the one time the tech from QNAP successfully started it before my unstable internet led to that repairman rebooting my router and cutting that putty session.

So again,thanks for this great utility C Granier or CG Ranier and I am pretty confident that nearly total watching only will get these one of a kind files back.

I just hope you can get me into your tiny miracle,

Jan-Willem

JWvanLohuizen
Posts: 7
Joined: 05 Jun 2020, 23:20

Re: testdisk_static on QNAP total Linux novice

#5 Post by JWvanLohuizen »

A really nice QNAP support tech provided the missing line of c;:

Code: Select all

cp -r /share/external/DEV3303_1/Test-Disk /tmp
cd /tmp/Test-Disk
ls
chmod +x testdisk_static
./testdisk_static
This is fixed

Thanks

JWvanLohuizen
Posts: 7
Joined: 05 Jun 2020, 23:20

Re: testdisk_static on QNAP total Linux novice

#6 Post by JWvanLohuizen »

.

Locked