maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   General (https://talk.maemo.org/forumdisplay.php?f=7)
-   -   7zip not working (https://talk.maemo.org/showthread.php?t=58169)

rokafellaskank 2010-07-10 13:52

7zip not working
 
can anyone help, it was working before, then it just stopped working.
here's what I get

~ $ cd /home/user/MyDocs/Downloads
~/MyDocs/Downloads $ 7z e set.7z
/usr/bin/7z: exec: line 2: /usr/lib/p7zip/7z: Too many levels of symbolic links
~/MyDocs/Downloads $

anyone got any ideas?

Joorin 2010-07-10 13:57

Re: 7zip not working
 
Just guessing:

The /usr/bin/7z file is a shell script that starts the binary that does the actual work. /usr/lib/p7zip/7z might also be a shell script for all I know.

Somewhere in this chain, something has changed, making it go in a loop trying to resolve the actual place where the binary is.

My suggestion would be to look at these files, follow the chain and see where it loops and break that loop.

rokafellaskank 2010-07-10 14:02

Re: 7zip not working
 
Quote:

Originally Posted by Joorin (Post 747223)
Just guessing:

The /usr/bin/7z file is a shell script that starts the binary that does the actual work. /usr/lib/p7zip/7z might also be a shell script for all I know.

Somewhere in this chain, something has changed, making it go in a loop trying to resolve the actual place where the binary is.

My suggestion would be to look at these files, follow the chain and see where it loops and break that loop.


thanks for the prompt response, but I wouldn't know where to look.

Joorin 2010-07-10 14:08

Re: 7zip not working
 
Use the file command to find out what kind of files you're going to investigate:
Code:

file /usr/bin/7z
If it's identified as a text file or shell script, look in it with
Code:

cat /usr/bin/7z
Now you 'll see what it does. Now have a look at /usr/lib/p7zip/7z in the same way.

rokafellaskank 2010-07-10 14:21

Re: 7zip not working
 
Quote:

Originally Posted by Joorin (Post 747231)
Use the file command to find out what kind of files you're going to investigate:
Code:

file /usr/bin/7z
If it's identified as a text file or shell script, look in it with
Code:

cat /usr/bin/7z
Now you 'll see what it does. Now have a look at /usr/lib/p7zip/7z in the same way.


~ $ file /usr/bin/7z
-sh: file: not found
~ $ cat /usr/bin/7z
#! /bin/sh
exec /usr/lib/p7zip/7z "$@"
~ $ /usr/lib/p7zip/7z
-sh: /usr/lib/p7zip/7z: Too many levels of symbolic links
~ $

that's what I got after them, I'm sorry, but I am a complete novice.

Joorin 2010-07-10 14:30

Re: 7zip not working
 
Quote:

Originally Posted by rokafellaskank (Post 747241)
~ $ file /usr/bin/7z
-sh: file: not found

Ah, I assumed the file command would be installed. My bad but no worries.

Quote:

~ $ cat /usr/bin/7z
#! /bin/sh
exec /usr/lib/p7zip/7z "$@"
This means that every time that you use the 7z command, the file /usr/lib/p7zip/7z will be called with all the arguments that you supplied.

Quote:

~ $ /usr/lib/p7zip/7z
-sh: /usr/lib/p7zip/7z: Too many levels of symbolic links
~ $

that's what I got after them, I'm sorry, but I am a complete novice.
The next step is to look at that special file:
Code:

cd /usr/lib/p7zip
ls -l

This will show you what is stored in that folder together with information about who can do what with the files. If I were to guess, you'll find something along the lines of
Code:

lrwxrwxrwx 1 root root <some date> 7z -> 7z
and that's a problem.

rokafellaskank 2010-07-10 14:38

Re: 7zip not working
 
~ $ cd /usr/lib/p7zip
/opt/maemo/usr/lib/p7zip $ ls -l
lrwxrwxrwx 1 root root 27 Jul 7 01:05 7z -> /opt/maemo/usr/lib/p7zip/7z
lrwxrwxrwx 1 root root 30 Jul 7 01:05 7z.so -> /opt/maemo/usr/lib/p7zip/7z.so
lrwxrwxrwx 1 root root 34 Jul 7 01:05 7zCon.sfx -> /opt/maemo/usr/lib/p7zip/7zCon.sfx
lrwxrwxrwx 1 root root 28 Jul 7 01:05 7za -> /opt/maemo/usr/lib/p7zip/7za
-rwxr-xr-x 1 root root 685292 Jan 11 16:53 7zr
/opt/maemo/usr/lib/p7zip $


so I guess it's not looking too good then. could I not uninstall 7z then re-install it, or is that too easy.

Joorin 2010-07-10 14:47

Re: 7zip not working
 
Three days a go someone, or something, messed up your 7zip installation. Uninstalling and installing might very well be the easiest way to fix it.

But depending on how messed up it is, the uninstalling might give some complaints, so be prepared for that.

rokafellaskank 2010-07-10 14:52

Re: 7zip not working
 
yea, that sounds about right, I was downloading ScummVm game torrents, that's when it stopped working.

so to uninstall it do I type

sudo gainroot
apt-get uninstall p7zip

that doesn't work, does anybody know how to un-install it?
cheers.

barzam 2010-07-10 15:19

Re: 7zip not working
 
Use the remove or purge switch, like
apt-get remove X
apt-get purge X

rokafellaskank 2010-07-10 15:29

Re: 7zip not working
 
Quote:

Originally Posted by barzam (Post 747287)
Use the remove or purge switch, like
apt-get remove X
apt-get purge X

thanks buddy.

rokafellaskank 2010-07-10 16:09

Re: 7zip not working
 
o.k. well I removed it, rebooted, installed it again and got the same problem. then i purged it, and installed it and what it's doing is using the original deb package.


~ $ sudo gainroot
Root shell enabled


BusyBox v1.10.2 (Debian 3:1.10.2.legal-1osso30+0m5) built-in shell (ash)
Enter 'help' for a list of built-in commands.


/home/user # apt-get install p7zip
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following NEW packages will be installed:
p7zip
0 upgraded, 1 newly installed, 0 to remove and 2 not upgraded.
Need to get 0B/349kB of archives.
After this operation, 1024kB of additional disk space will be used.
Selecting previously deselected package p7zip.
(Reading database ... 48374 files and directories currently installed.)
Unpacking p7zip (from .../p7zip_9.04~dfsg.1-1-m5-1_armel.deb) ...
Setting up p7zip (9.04~dfsg.1-1-m5-1) ...
/home/user #


so I'm back to square one again.
anyone have any idea what to do next.
cheers.

dannym 2010-07-10 19:50

Re: 7zip not working
 
hmm... sounds like the person that packaged p7zip messed up then? try contacting him...

to make sure you can get a file list of the installed package by
dpkg -L p7zip

and if you are really adventurous, dissect the deb file by:

mkdir junk
cd junk
ar x p7zip*.deb
gunzip data.tar.gz
tar xf data.tar
and if you are lucky you will find the 7z binary in the innards now spilled into the "junk" directory. That is a gross way of going about it but the fastest way to advance: to sidestep the entire packager...

edit: to get "ar", apt-get install binutils

int_ua 2010-07-17 12:40

Re: 7zip not working
 
AFAIK, 7z is provided by package p7zip-full
p7zip gives only 7zr.
Had the same problem with 7z, trying to use 7zr...

int_ua 2010-07-17 13:06

Re: 7zip not working
 
Code:

$ file /usr/lib/p7zip/7z
/usr/lib/p7zip/7z: broken symbolic link to
 `/opt/maemo/usr/lib/p7zip/7z'

$ ls -l /opt/maemo/usr/lib/p7zip/
lrwxrwxrwx    1 root    root          27 Jul 17 15:59
 7z -> /opt/maemo/usr/lib/p7zip/7z
lrwxrwxrwx    1 root    root          30 Jul 17 15:59
 7z.so -> /opt/maemo/usr/lib/p7zip/7z.so
lrwxrwxrwx    1 root    root          34 Jul 17 15:59
 7zCon.sfx -> /opt/maemo/usr/lib/p7zip/7zCon.sfx
lrwxrwxrwx    1 root    root          28 Jul 17 15:59
 7za -> /opt/maemo/usr/lib/p7zip/7za

awesome


All times are GMT. The time now is 18:59.

vBulletin® Version 3.8.8