[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#652987: FWD: Bug#652987: the cdrom path is not disabled in sources.list



Forwarding to live team for your help. Does it make sense to always
disable the CD in sources.list for live systems? If live systems
contain some sort of package archive at all, and it's not complete,
should they put "not_complete" into /cdrom/.disk/cd_type ?

----- Forwarded message from prathibhab@cdac.in -----

Date: Thu, 22 Dec 2011 19:52:51 +0530 (IST)
From: prathibhab@cdac.in
To: submit@bugs.debian.org
Subject: Bug#652987: the cdrom path is not disabled in sources.list
Reply-To: prathibhab@cdac.in, 652987@bugs.debian.org
X-Mailer: TWIG 2.8.3


Package: apt-setup
version: 0.56

While installing debian using the live-installer package, the cdrom path
in the sources.list exists after the completion of the installation in
sources.list. While reloading the synaptic package manager, it shows the
error: "Failed to load cdrom..."

A patch for resolving this issue is attached.

-- 
Regards,
Prathibha
C-DAC
Chennai



-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.


diff -Naur apt-setup-0.56-orig/finish-install.d/10apt-cdrom-setup apt-setup-0.56/finish-install.d/10apt-cdrom-setup
--- apt-setup-0.56-orig/finish-install.d/10apt-cdrom-setup	2011-06-19 08:08:25.000000000 +0530
+++ apt-setup-0.56/finish-install.d/10apt-cdrom-setup	2011-12-22 09:17:48.000000000 +0530
@@ -1,12 +1,16 @@
 #! /bin/sh
 set -e
 
-# Disable netinst CD image in sources.list if any other sources are present
-if [ -e /cdrom/.disk/base_installable ] && \
-   [ -e /cdrom/.disk/cd_type ] && \
-   [ "$(cat /cdrom/.disk/cd_type)" = not_complete ] && \
-   grep -q "^deb \(ht\|f\)tp" /target/etc/apt/sources.list; then
-	logger -t finish-install "Disabling netinst CD in sources.list"
-	sed -i "/^deb cdrom:/s/^/#/" /target/etc/apt/sources.list
-	log-output -t finish-install chroot /target apt-get update
+disable_cdrom_path()
+{
+   logger -t finish-install "Disabling the install CD path in sources.list"
+   sed -i "/^deb cdrom:/s/^/#/" /target/etc/apt/sources.list
+   log-output -t finish-install chroot /target apt-get update
+}
+
+# Disable CD path in sources.list
+if [ -e /cdrom/.disk/base_installable ] && [ -e /cdrom/.disk/cd_type ] && \
+   ( [ "$(cat /cdrom/.disk/cd_type)" = not_complete ] && grep -q "^deb \(ht\|f\)tp" /target/etc/apt/sources.list ) || \
+   ( [ "$(cat /cdrom/.disk/cd_type)" = live ] && grep -q "^deb cdrom:" /target/etc/apt/sources.list ); then
+ 	disable_cdrom_path
 fi


----- End forwarded message -----
-- 
see shy jo

Attachment: signature.asc
Description: Digital signature


Reply to: