Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[solved] Trouble recognizing cd/dvd drive
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware
View previous topic :: View next topic  
Author Message
PCC322
n00b
n00b


Joined: 29 May 2019
Posts: 48

PostPosted: Tue Jul 16, 2019 5:04 pm    Post subject: [solved] Trouble recognizing cd/dvd drive Reply with quote

My computer is not recognizing discs in my cd/dvd drive. Nothing is showing up with
Code:
 lsblk
except for my sda partitions. Looking through the Gentoo handbook it looks like I may have missed a setting in the kernel needed for cd drives. I believe that I updated this in the kernel config but I am not sure if I went through the correct process to make and apply the new kernel.

Last edited by PCC322 on Sun Jul 28, 2019 5:51 am; edited 1 time in total
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 44945
Location: 56N 3W

PostPosted: Tue Jul 16, 2019 6:37 pm    Post subject: Reply with quote

PCC322,

What does
Code:
uname -a
tell?

Code:
$ uname -a
Linux NeddySeagoon_Static 5.1.1-gentoo #1 SMP PREEMPT Sun May 12 09:46:42 BST 2019 x86_64 AMD Phenom(tm) II X6 1090T Processor AuthenticAMD GNU/Linux

The Sun May 12 09:46:42 BST 2019 there is the build time of the running kernel.
That's OK for me.

You look at the build time of your running kernel and work out if you have a newer kernel or not.
If you do, its not yet in use.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
PCC322
n00b
n00b


Joined: 29 May 2019
Posts: 48

PostPosted: Wed Jul 17, 2019 8:05 am    Post subject: Reply with quote

It is looking like I am still using the old kernel.
Back to top
View user's profile Send private message
PCC322
n00b
n00b


Joined: 29 May 2019
Posts: 48

PostPosted: Thu Jul 18, 2019 7:42 pm    Post subject: Reply with quote

In kernel configuration, I am looking at the Serial ATA and parallel ATA drivers, is there a way to know which drivers I should enable for my CD/DVD drive?

I am using an old Toshiba AMD laptop so I am assuming some of the things like SATA port multiplier support is not going to be relevant.

Would there be harm, other than consuming a lot of time, to enabling all of these driver, getting the drive and software up and running, then disabling options until I find on that causes the drive to stop working?
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 44945
Location: 56N 3W

PostPosted: Thu Jul 18, 2019 8:29 pm    Post subject: Reply with quote

PCC322,

The output of
Code:
lspci
will tell.
At least, that will (indirectly) tell the chipset driver.

After that its
Code:
  │ │    <*> SCSI CDROM support     
  │ │    [ ]   Enable vendor-specific extensions (for SCSI CDROM)

You may want the second option there. Its harmless bloat if you don't need it.

-- edit --

Code:
<*> SCSI generic support
is needed for writing blank optical media.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
PCC322
n00b
n00b


Joined: 29 May 2019
Posts: 48

PostPosted: Fri Jul 19, 2019 8:27 am    Post subject: Reply with quote

Looks like I have an AMD sb600 for IDE and SATA. I enabled what seemed to be the only AMD driver option in the kernel. I am making the kernel now and saw a bunch of entries of "unmet direct dependency detected", should I be concerned? It seems to be proceeding normally after that initial bit.
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 44945
Location: 56N 3W

PostPosted: Fri Jul 19, 2019 10:38 am    Post subject: Reply with quote

PCC322,

"unmet direct dependency detected" means that there is something configured in your kernel that needs something else that is not selected.
Your kernel will be broken.

Exactly how did you configure your kernel?
The wrong answer is that you used you favourite text editor.
The kernel configuration tools can flip over half a dozen .config options for one change.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
PCC322
n00b
n00b


Joined: 29 May 2019
Posts: 48

PostPosted: Fri Jul 19, 2019 6:05 pm    Post subject: Reply with quote

I used the
Code:
 make menuconfig
interface as instructed in Gentoo install handbook.
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 44945
Location: 56N 3W

PostPosted: Fri Jul 19, 2019 6:36 pm    Post subject: Reply with quote

PCC322,

Code:
make menuconfig
is one of the right answers. There are other kernel config tools too.

Does the date command show the current date and time?
The make step will get in a mess if your time ever steps backwards.

If in doubt, start with
Code:
make clean
this removes all the binary files created as a result of a previous make.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
PCC322
n00b
n00b


Joined: 29 May 2019
Posts: 48

PostPosted: Fri Jul 19, 2019 6:42 pm    Post subject: Reply with quote

Date command is returning the correct time and date.

I ran
Code:
 make clean
guess I will try it again.

I have been getting an error printing in my terminal periodically which I have not yet attempted to fix:

Code:
 syslogd: /var/log/news/news.crit: No such file or directory
and three more similar lines, could this be throwing off my kernel setup?
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 44945
Location: 56N 3W

PostPosted: Fri Jul 19, 2019 6:45 pm    Post subject: Reply with quote

PCC322,

I'm not a systemd user but I don't think that will be an issue.
The kernel build does nothing outside of the kernel source tree itself
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
PCC322
n00b
n00b


Joined: 29 May 2019
Posts: 48

PostPosted: Fri Jul 19, 2019 6:48 pm    Post subject: Reply with quote

NeddySeagoon wrote:
PCC322,

I'm not a systemd user but I don't think that will be an issue.
The kernel build does nothing outside of the kernel source tree itself


Okay, though I don't think it is systemd as I have not emerged anything with systemd support as best I can tell.
Back to top
View user's profile Send private message
PCC322
n00b
n00b


Joined: 29 May 2019
Posts: 48

PostPosted: Sat Jul 20, 2019 7:53 am    Post subject: Reply with quote

I tried again but am still getting messages about unmet dependencies. I noticed that I get a sort of scrambled screen when I save from menuconfig, screenshot here;
[img]https://i.postimg.cc/hJhbcBxj/20190720-023246.jpg[/img]

Is there a way to load the settings used on the kernel I am presently using into menuconfig and see what happens changing one setting at a time?
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 44945
Location: 56N 3W

PostPosted: Sat Jul 20, 2019 8:54 am    Post subject: Reply with quote

PCC322,

The kernel .config you are presently using is available at /proc/config.gz if you have that kernel option on in the running kernel.
Its also in the top level of the old kernel tree as .config.

Copy the .config file from one kernel tree to the other, then run
Code:
make oldconfig
in the new kernel.
oldconfig does three things
    It drops .config symbols that have disappeared

    It leaves existing settings untouched

    It asks you to choose setting for new options


oldconfig also hints at new settings with the capital letter in the prompt.
The capitals are the default settings in the new kernel.

If you start with the compressed /proc/config.gz, you need to decompress it before the kernel make system will use it.

The scrambled video is nothing to worry about. What actually happens behind the scenes is corrert.
The video driver is drawing the screen incorrectly.
Its one of a class of features called 'video artefacts'.
They are all harmless but ugly.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
PCC322
n00b
n00b


Joined: 29 May 2019
Posts: 48

PostPosted: Sat Jul 20, 2019 10:09 pm    Post subject: Reply with quote

NeddySeagoon wrote:
PCC322,

The kernel .config you are presently using is available at /proc/config.gz if you have that kernel option on in the running kernel.
Its also in the top level of the old kernel tree as .config..


I don't have a config.gz (or anything similar) in /proc, I should make a point of enabling that go through the kernel again.

What is the old kernel tree? Is that in /usr/src/linux? There is a file called .config (the saved setting from the last time I ran make menuconfig that resulted in unmet dependencies) and also a .config.old. I am not sure what .config.old is.
Back to top
View user's profile Send private message
PCC322
n00b
n00b


Joined: 29 May 2019
Posts: 48

PostPosted: Sun Jul 21, 2019 5:28 am    Post subject: Reply with quote

So I decided to use
Code:
 make defconfig
to start from a default configuration, which produced settings which I was able to make (compile?), then went through the menuconfig to set up the kernel following the install Handbook and the CDROM entry in Gentoo wiki, making less of an effort that I did initially to disable things I didn't think I would need figuring I can go though it again later, or not. I ran
Code:
 make install
. In /boot I have config-4.19.52-gentoo, System.map-4.19.52-gentoo, vmlinuz-4.19.52-gentoo, and .old versions of each of these. Despite following the Handbook for GRUB2, I didn't have a grub directory in /boot, though I do now, inside of which I have a .cfg file which, if I am readying the code correctly, I should have option for the current kernel, the .old kernel, and recovery mode for each under the advanced options. However, when I am booting and get to GRUB I only have the current kernel, which was the initial one I compiled. I am thinking I might have GRUB working for a different directory than /boot.
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 44945
Location: 56N 3W

PostPosted: Sun Jul 21, 2019 8:41 am    Post subject: Reply with quote

PCC322,

You must make sure that /boot is mounted for the
Code:
make install

Its not mounted by default in Gentoo.

If you are installing a new (different version) and not overwriting an old kernel, you need to tell grub about it.
There is a command to rewrite your grub.cnf. I'm still on old grub.

Lastly, you new kernel may be on the advanced menu in grub and not your default kernel.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
PCC322
n00b
n00b


Joined: 29 May 2019
Posts: 48

PostPosted: Mon Jul 22, 2019 3:19 am    Post subject: Reply with quote

NeddySeagoon wrote:
PCC322,

You must make sure that /boot is mounted for the
Code:
make install

Its not mounted by default in Gentoo.

If you are installing a new (different version) and not overwriting an old kernel, you need to tell grub about it.
There is a command to rewrite your grub.cnf. I'm still on old grub.

Lastly, you new kernel may be on the advanced menu in grub and not your default kernel.


For this I would
Code:
 mount sda0 /boot
, or something to that effect, after doing so I will likely see the /boot/grub directory with grub.cfg?
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 44945
Location: 56N 3W

PostPosted: Mon Jul 22, 2019 8:34 am    Post subject: Reply with quote

PCC322,

Code:
mount /boot
should work as boot should be defined in /etc/fstab
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
PCC322
n00b
n00b


Joined: 29 May 2019
Posts: 48

PostPosted: Wed Jul 24, 2019 8:17 am    Post subject: Reply with quote

Well, I am sort of making some progress, I was able to mount /boot but needed to use
Code:
 mount /dev/sda2 /boot
because
Code:
 mount /boot
returns an error for wrong fs type, bad option, bad superblock on /dev/sda2, etc. However, with /boot mounted I was able to make the kernel and grub to boot with it and was able to verify it was a new kernel. However, I am still not able to get sr0 to show up with lsblk.

I booted from the install medium, which showed /dev/sr0, though when I attempted it mount it, it returned an error about being unable to read superblock on sr0.

Where should I start looking now?
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 44945
Location: 56N 3W

PostPosted: Wed Jul 24, 2019 8:56 pm    Post subject: Reply with quote

PCC322,

If mount /boot failed, you have an error in the /boot entry in /etc/fstab.

/dev/sr0 is your CD drive. Was there a CD in the drive?
Audio CDs do not have a filesystem, so cannot be mounted. They are played using raw block lists.
DVDs (films) usually have two filesystems, ISO9660 and UDF. They are both deliberately corrupt and again, successful replay uses raw block lists.
DVDs can usually be mounted though.

If your own kernel has /proc/config.gz decompress it and post it on a pastebin.
Give us the link.

If you don't have /proc/config.gz pastebin youur kernel .config file.

To play audio CDs and DVDs, your user needs to be in the cdrom group.
To write optical media, cdrw membership is required.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
PCC322
n00b
n00b


Joined: 29 May 2019
Posts: 48

PostPosted: Sun Jul 28, 2019 5:51 am    Post subject: Reply with quote

I got my drive working. After going through some trouble learning how to configure and install a new kernel, I basically included every sata/pata driver that wasn't experimental in the kernel and am now able to mount data CDs. I guess I can now spend time disabling all the stuff I just enabled and try to determine which drivers I actually needed.
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 44945
Location: 56N 3W

PostPosted: Sun Jul 28, 2019 10:05 am    Post subject: Reply with quote

PCC322,

The output of
Code:
lspci -k
will take most of the guesswork out of the kernel pruning.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum