Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

chroot error

New to Debian (Or Linux in general)? Ask your questions here!
Post Reply
Message
Author
haoyihuan
Posts: 10
Joined: 2012-05-20 05:58

chroot error

#1 Post by haoyihuan »

i get an error, while hit command:
sudo debootstrap lucid /media/documents/lucid/
W: Failure trying to run: chroot /media/documents/lucid dpkg --force-depends --install /var/cache/apt/archives/base-files_5.0.0ubuntu20_amd64.deb /var/cache/apt/archives/base-passwd_3.5.22_amd64.deb
:idea:

User avatar
nadir
Posts: 5961
Joined: 2009-10-05 22:06
Location: away

Re: chroot error

#2 Post by nadir »

different path
|
without lucid

works?
"I am not fine with it, so there is nothing for me to do but stand aside." M.D.

haoyihuan
Posts: 10
Joined: 2012-05-20 05:58

Re: chroot error

#3 Post by haoyihuan »

nadir wrote:different path
|
without lucid

works?
Same error while:
sudo debootstrap sid /media/documents/chroot-test/
W: Failure trying to run: chroot /media/documents/chroot-test dpkg --force-depends --install /var/cache/apt/archives/base-files_6.8_amd64.deb /var/cache/apt/archives/base-passwd_3.5.24_amd64.deb

More testing:
sudo chroot /media/documents/chroot-test/
dpkg --force-depends --install /var/cache/apt/archives/base-files_6.8_amd64.deb /var/cache/apt/archives/base-passwd_3.5.24_amd64.deb
dpkg: warning: parsing file '/var/lib/dpkg/status' near line 28 package 'dpkg':
missing description
dpkg: warning: parsing file '/var/lib/dpkg/status' near line 28 package 'dpkg':
missing maintainer
dpkg: warning: parsing file '/var/lib/dpkg/status' near line 28 package 'dpkg':
missing architecture
dpkg: regarding .../base-files_6.8_amd64.deb containing base-files, pre-dependency problem:
base-files pre-depends on awk
awk is not installed.
dpkg: warning: ignoring pre-dependency problem!
(Reading database ... 38 files and directories currently installed.)
Unpacking base-files (from .../base-files_6.8_amd64.deb) ...
dpkg: error processing /var/cache/apt/archives/base-files_6.8_amd64.deb (--install):
symbolic link '/usr/share/common-licenses/LGPL' size has changed from 20 to 6
Preparing to replace base-passwd 3.5.24 (using .../base-passwd_3.5.24_amd64.deb) ...
Unpacking replacement base-passwd ...
dpkg: base-passwd: dependency problems, but configuring anyway as you requested:
base-passwd depends on libc6 (>= 2.2.5); however:
Package libc6 is not installed.
Setting up base-passwd (3.5.24) ...
Errors were encountered while processing:
/var/cache/apt/archives/base-files_6.8_amd64.deb
"/var/lib/dpkg/status" contents
cat /var/lib/dpkg/status
Package: base-files
Status: install ok not-installed
Priority: required
Section: admin
Architecture: i386

Package: base-passwd
Essential: yes
Status: install ok installed
Priority: required
Section: admin
Installed-Size: 162
Maintainer: Colin Watson <cjwatson@debian.org>
Architecture: i386
Multi-Arch: foreign
Version: 3.5.24
Replaces: base
Depends: libc6 (>= 2.1)
Description: Debian base system master password and group files
These are the canonical master copies of the user database files
(/etc/passwd and /etc/group), containing the Debian-allocated user and
group IDs. The update-passwd tool is provided to keep the system databases
synchronized with these master files.

Package: dpkg
Status: install ok installed
Version: 1.16.3

User avatar
www
Posts: 37
Joined: 2012-05-23 05:53
Location: ::1:

Re: chroot error

#4 Post by www »

Please post the output of the following:

Code: Select all

#schroot -l
- debian GNU/Linux 7.0a1 | unstable/wheezy | openbox | mario cr-48 hardware -

"Privacy is necessary for an open society in the electronic age. Privacy is not secrecy. Privacy is the power to selectively reveal oneself to the world."

haoyihuan
Posts: 10
Joined: 2012-05-20 05:58

Re: chroot error

#5 Post by haoyihuan »

www wrote:Please post the output of the following:

Code: Select all

#schroot -l

Code: Select all

$ schroot -l
chroot:default
chroot:sid
chroot:unstable

dose debootstrap works with schroot?

User avatar
www
Posts: 37
Joined: 2012-05-23 05:53
Location: ::1:

Re: chroot error

#6 Post by www »

You need to reconfigure as chroot parameters are only set for Sid.

You are currently running lucid.

sent via mobile ..
- debian GNU/Linux 7.0a1 | unstable/wheezy | openbox | mario cr-48 hardware -

"Privacy is necessary for an open society in the electronic age. Privacy is not secrecy. Privacy is the power to selectively reveal oneself to the world."

User avatar
www
Posts: 37
Joined: 2012-05-23 05:53
Location: ::1:

Re: chroot error

#7 Post by www »

Run the following command

mk-sbuild --arch i386 --vg=schroot-vol --distro=debian wheezy


mk-sbuild is the command
"--arch i386" is the architecture, either i386 or amd64(for x86_64)
"--vg=schroot-vol" is the volume group (remember the LVM volume requirements above?) thats the target storage area.
"--distro=debian" is either debian or ubuntu, default to ubuntu, so if you want to use debian, this must be set as the example shows.
"wheezy" is the actual version, which can be any debian/ubuntu version available from the official repositories (supported by the tool also ofc), like debian: lenny, squeeze, wheezy, testing and sid
sent via mobile ..
- debian GNU/Linux 7.0a1 | unstable/wheezy | openbox | mario cr-48 hardware -

"Privacy is necessary for an open society in the electronic age. Privacy is not secrecy. Privacy is the power to selectively reveal oneself to the world."

haoyihuan
Posts: 10
Joined: 2012-05-20 05:58

Re: chroot error

#8 Post by haoyihuan »

Thanks for www.

My host:debian squeeze amd64
My chroot:debian sid amd64

/var/lib/dpkg/status:
Host:

Code: Select all

Package: base-files
Essential: yes
Status: install ok installed
Priority: required
Section: admin
Installed-Size: 394
Maintainer: Santiago Vila <sanvila@debian.org>
Architecture: amd64
Version: 6.0squeeze5
Replaces: base, dpkg (<= 1.15.0), miscutils
Provides: base
Pre-Depends: awk
Conffiles:
 /etc/debian_version 1c683b3498356ccfa171f1bb1aeaee54
 /etc/dpkg/origins/debian 731423fa8ba067262f8ef37882d1e742
 /etc/host.conf 4eb63731c9f5e30903ac4fc07a7fe3d6
 /etc/issue 174fd67875b42f41746ea8ae50f9b4b7
 /etc/issue.net d31a0dfcf85bef9935a105b361a9d47b
Description: Debian base system miscellaneous files
 This package contains the basic filesystem hierarchy of a Debian system, and
 several important miscellaneous files, such as /etc/debian_version,
 /etc/host.conf, /etc/issue, /etc/motd, /etc/profile, /etc/nsswitch.conf,
 and others, and the text of several common licenses in use on Debian systems.
...
Package: dpkg
Essential: yes
Status: install ok installed
Priority: required
Section: admin
Installed-Size: 6984
Origin: debian
Maintainer: Dpkg Developers <debian-dpkg@lists.debian.org>
Bugs: debbugs://bugs.debian.org
Architecture: amd64
Version: 1.15.8.12
Pre-Depends: libbz2-1.0, libc6 (>= 2.6), libselinux1 (>= 1.32), zlib1g (>= 1:1.1.4), coreutils (>= 5.93-1), xz-utils
Suggests: apt
Breaks: apt (<< 0.7.7), aptitude (<< 0.4.7-1), dpkg-dev (<< 1.15.8), libdpkg-perl (<< 1.15.8), pinfo (<< 0.6.9-3.1), tkinfo (<< 2.8-3.1)
Conffiles:
 /etc/dpkg/dpkg.cfg f4413ffb515f8f753624ae3bb365b81b
 /etc/alternatives/README 69c4ba7f08363e998e0f2e244a04f881
 /etc/cron.daily/dpkg b6b8dc21210ea50db7cc4636f521758f
 /etc/logrotate.d/dpkg 782ea5ae536f67ff51dc8c3e2eeb4cf9
Description: Debian package management system
 This package provides the low-level infrastructure for handling the
 installation and removal of Debian software packages.
 .
 For Debian package development tools, install dpkg-dev.
Homepage: http://wiki.debian.org/Teams/Dpkg
chroot:

Code: Select all

Package: base-files
Status: install ok not-installed
Priority: required
Section: admin
Architecture: amd64

Package: dpkg
Status: install ok installed
Version: 1.16.3


Dose it offer some infomations?

User avatar
kiyop
Posts: 3983
Joined: 2011-05-05 15:16
Location: Where persons without desire to improve themselves fear to tread, in Japan
Been thanked: 3 times

Re: chroot error

#9 Post by kiyop »

Do you understand www's post?
www wrote:You need to reconfigure as chroot parameters are only set for Sid.

You are currently running lucid.

sent via mobile ..
www wrote:Run the following command

mk-sbuild --arch i386 --vg=schroot-vol --distro=debian wheezy


mk-sbuild is the command
"--arch i386" is the architecture, either i386 or amd64(for x86_64)
"--vg=schroot-vol" is the volume group (remember the LVM volume requirements above?) thats the target storage area.
"--distro=debian" is either debian or ubuntu, default to ubuntu, so if you want to use debian, this must be set as the example shows.
"wheezy" is the actual version, which can be any debian/ubuntu version available from the official repositories (supported by the tool also ofc), like debian: lenny, squeeze, wheezy, testing and sid
sent via mobile ..
haoyihuan wrote:
sudo chroot /media/documents/chroot-test/
dpkg --force-depends --install /var/cache/apt/archives/base-files_6.8_amd64.deb /var/cache/apt/archives/base-passwd_3.5.24_amd64.deb
dpkg: warning: parsing file '/var/lib/dpkg/status' near line 28 package 'dpkg':
missing description
dpkg: warning: parsing file '/var/lib/dpkg/status' near line 28 package 'dpkg':
missing maintainer
dpkg: warning: parsing file '/var/lib/dpkg/status' near line 28 package 'dpkg':
missing architecture
dpkg: regarding .../base-files_6.8_amd64.deb containing base-files, pre-dependency problem:
base-files pre-depends on awk
awk is not installed.
(snip)
base-passwd depends on libc6 (>= 2.2.5); however:
Package libc6 is not installed.
Setting up base-passwd (3.5.24) ...
Errors were encountered while processing:
/var/cache/apt/archives/base-files_6.8_amd64.deb
"/var/lib/dpkg/status" contents
cat /var/lib/dpkg/status
Package: base-files
(snip)
Depends: libc6 (>= 2.1)
Have you read http://www.debian.org/releases/stable/i386/apds03.html ?

How about adding URL of the necessary mirror at the end of "debootstrap" command?
Openbox, JWM: Jessie, Sid, Arch / Win XP (on VirtualBox), 10
http://kiyoandkei.bbs.fc2.com/

haoyihuan
Posts: 10
Joined: 2012-05-20 05:58

Re: chroot error

#10 Post by haoyihuan »

Thanks kiyop.

I think, it was "debootstrap" causes the error.

I've read the page "http://www.debian.org/releases/stable/i386/apds03.html".
There is no messages about my eroors.

While my mirrors added, same error appears.
My mirrors is http://mirrors.ustc.edu.cn/debian.

User avatar
kiyop
Posts: 3983
Joined: 2011-05-05 15:16
Location: Where persons without desire to improve themselves fear to tread, in Japan
Been thanked: 3 times

Re: chroot error

#11 Post by kiyop »

I think that you configured network setting wrongly or that you should use "apt-get install" or "aptitude install" or so instead of "dpkg --install" if you configured correctly.

I succeeded in installing debian squeeze by using debootstrap according to
http://www.debian.org/releases/stable/i386/apds03.html
It was my first time to install debian by using debootstrap.
Please be noticed that the following sentence in the above URL is wrong:
In this section, $ symbolizes a command to be entered in the user's current system, while # refers to a command entered in the Debian chroot.
I booted debian squeeze installed in an partition in an internal HDD.
I made an ext4 patition in an newly-formatted external HDD (with msdos-partition table).
I executed like D.3.1 to D.3.5 in the above URL, in order to install debian squeeze into the made ext4 partition.
I have grub2 installed in an internal HDD, so I need not install grub2 again.

After I finished the above, I rebooted and I manually load the kernel and the initramfs in the partition and gave the folliowing:
root=UUID=UUID of the partition debian squeeze was installed on ro
as kernel option, and booted.
Then successfully debian squeeze installed on the partition in the external HDD booted into CLI.
I was asked password (for root) to log in but I have not set any password for root. I have not made any ordinary user.
I think that the manual (the above URL) should suggest to set root pass word by "passwd" command and also to add an ordinary user by "adduser" command.

So, I pressed CTRL+ALT+DEL to restart and then booted again with kernel option:
root=UUID=UUID of the partition debian squeeze was installed on rw single init=/bin/bash
I could log in to the debian squeeze with single user mode with the / partition is mounted as read-write mode.
# passwd
and typed the root password.
# adduser USER_NAME
and typed the user's password and set its configuration.
# ifconfig -a
shows that eth3 is the network (LAN). Thus,
# dhclient eth3
# apt-get update
Then necessary files are downloaded successfully, and
# apt-get install grub2
and installed grub2 code onto the external HDD.
Also, "grub-install" worked correctly.
# update-grub
also worked correctly.
# sync
# exit
made system freeze. Thus, I pushed the power bottom more than 5 seconds to turn off the computer.

I turned on the computer and I could successfully boot the installed debian squeeze and log in to CLI.
Now, I finished installing xorg, alsa, xfonts-intl-japanese, iceweasel, iceweasel-l10n-ja, openbox, menu, menu-l10n, scim-anthy, ttf-takao-gothic and so on, and I can browse WEB with Japanese input method on the installed debian squeeze.

I think that you can install squeeze first and then upgrade to wheezy or sid.
Openbox, JWM: Jessie, Sid, Arch / Win XP (on VirtualBox), 10
http://kiyoandkei.bbs.fc2.com/

haoyihuan
Posts: 10
Joined: 2012-05-20 05:58

Re: chroot error

#12 Post by haoyihuan »

Thanks kiyop.

I didnot use a partition but a directory (/media/documents/chroot-test, with /dev/sda8 mounted on /media/documents, and chroot-test is a directory on /dev/sda8).

Becuase of the error, there isn't apt-get and aptitude.

Dose it cause my debootstrap not work?

User avatar
kiyop
Posts: 3983
Joined: 2011-05-05 15:16
Location: Where persons without desire to improve themselves fear to tread, in Japan
Been thanked: 3 times

Re: chroot error

#13 Post by kiyop »

haoyihuan wrote:I didnot use a partition but a directory (/media/documents/chroot-test, with /dev/sda8 mounted on /media/documents, and chroot-test is a directory on /dev/sda8).

Becuase of the error, there isn't apt-get and aptitude.

Dose it cause my debootstrap not work?
Maybe.

But once again I want to notice you:
kiyop wrote: Do you understand www's post?
www wrote:You need to reconfigure as chroot parameters are only set for Sid.

You are currently running lucid.

sent via mobile ..
www wrote:Run the following command

mk-sbuild --arch i386 --vg=schroot-vol --distro=debian wheezy


mk-sbuild is the command
"--arch i386" is the architecture, either i386 or amd64(for x86_64)
"--vg=schroot-vol" is the volume group (remember the LVM volume requirements above?) thats the target storage area.
"--distro=debian" is either debian or ubuntu, default to ubuntu, so if you want to use debian, this must be set as the example shows.
"wheezy" is the actual version, which can be any debian/ubuntu version available from the official repositories (supported by the tool also ofc), like debian: lenny, squeeze, wheezy, testing and sid
sent via mobile ..
How did you install debootstrap?

I succeeded in installing debian sid on a partition (/dev/sda8, ext4) by starting with debootstrap executed at debian squeeze installed on /dev/sdb5:
# /usr/sbin/debootstrap --arch i386 sid /mnt http://ftp.jaist.ac.jp/debian
after mounting /dev/sda8 on /mnt.
Openbox, JWM: Jessie, Sid, Arch / Win XP (on VirtualBox), 10
http://kiyoandkei.bbs.fc2.com/

haoyihuan
Posts: 10
Joined: 2012-05-20 05:58

Re: chroot error

#14 Post by haoyihuan »

hi,kiyop

I installed debootstrap with apt-get install. Before install it, I have upgraded.

When I install debootstrap before upgraded, it works well.

Is it a bug?

User avatar
kiyop
Posts: 3983
Joined: 2011-05-05 15:16
Location: Where persons without desire to improve themselves fear to tread, in Japan
Been thanked: 3 times

Re: chroot error

#15 Post by kiyop »

haoyihuan wrote:I installed debootstrap with apt-get install. Before install it, I have upgraded.

When I install debootstrap before upgraded, it works well.

Is it a bug?
I am not sure, but maybe the following page shows the bugs of debootstrap of unstable.
http://bugs.debian.org/cgi-bin/pkgrepor ... t=unstable

Have you updated the packages often?

How about using debootstrap on stable (squeeze)?
Openbox, JWM: Jessie, Sid, Arch / Win XP (on VirtualBox), 10
http://kiyoandkei.bbs.fc2.com/

haoyihuan
Posts: 10
Joined: 2012-05-20 05:58

Re: chroot error [fixed]

#16 Post by haoyihuan »

kiyop wrote: Have you updated the packages often?

How about using debootstrap on stable (squeeze)?
Yes to all.
Last edited by haoyihuan on 2012-06-02 05:53, edited 1 time in total.

User avatar
kiyop
Posts: 3983
Joined: 2011-05-05 15:16
Location: Where persons without desire to improve themselves fear to tread, in Japan
Been thanked: 3 times

Re: chroot error

#17 Post by kiyop »

Thanks for your reply.
Excuse me, I have not been noticed:
haoyihuan wrote:My host:debian squeeze amd64
My chroot:debian sid amd64
I succeeded in installing sid by using debootstrap on squeeze (on i386 machine).
You failed. The difference may be....
debootstrap on amd64 has bug(?).
Did you try to install to the whole partition (not to directory) ?
What commands did you execute to install sid with debootstrap on squeeze? Write concretely.
How about using "su -" instead of "sudo BLAH BLAH"?
Could you connect to the internet on the host debian squeeze amd64 when you executed debootstrap?
Openbox, JWM: Jessie, Sid, Arch / Win XP (on VirtualBox), 10
http://kiyoandkei.bbs.fc2.com/

haoyihuan
Posts: 10
Joined: 2012-05-20 05:58

Re: chroot error

#18 Post by haoyihuan »

Thanks, kiyop.

The problem disappears, when I debootstrap the sid on /sid-32 it woks.

While debootstrap the sid on /opt/sid, it also can work well.

My previous directory /media/documents is a ntfs partition. Whether debootstrap sid on /media/documents/sid or debootstrap sid /media/documents, it can not work.

And I debootstrap sid on an ext4 partition. It can run well.

Does NTFS filesystem breake it ?

User avatar
kiyop
Posts: 3983
Joined: 2011-05-05 15:16
Location: Where persons without desire to improve themselves fear to tread, in Japan
Been thanked: 3 times

Re: chroot error

#19 Post by kiyop »

haoyihuan wrote:My previous directory /media/documents is a ntfs partition. Whether debootstrap sid on /media/documents/sid or debootstrap sid /media/documents, it can not work.

And I debootstrap sid on an ext4 partition. It can run well.

Does NTFS filesystem breake it ?
Using debootstrap and/or chroot to NTFS partition (or to directory in NTFS partition) in order to install debian on it !!??
:shock: :lol: :mrgreen: :P ..... NO KIDDING! :wink:

I could not imagine that you tried to do such a thing. :wink:

NTFS filesystem is not like ext2, ext3, ext4 filesystems.
For example, permissions, owner, group of each file and/or of directory cannot be set individually on NTFS filesystem by linux. (Maybe my English is bad.)
Furthermore, symlinks can not work correctly on NTFS filesystem.

By the way, congratulations on your success! :D
Openbox, JWM: Jessie, Sid, Arch / Win XP (on VirtualBox), 10
http://kiyoandkei.bbs.fc2.com/

haoyihuan
Posts: 10
Joined: 2012-05-20 05:58

Re: chroot error

#20 Post by haoyihuan »

Thanks for all helps.

Post Reply