Re: mounting cdrom within function system()
From: Arnoud (galactus_at_stack.nl)
Date: 10/28/04
- Next message: sam: "Re: mounting cdrom within function system()"
- Previous message: Eric Masson: "Re: USB to serial cable"
- In reply to: sam: "Re: mounting cdrom within function system()"
- Next in thread: sam: "Re: mounting cdrom within function system()"
- Reply: sam: "Re: mounting cdrom within function system()"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Thu, 28 Oct 2004 13:54:09 +0000 (UTC)
In article <clqucl$2pm7$1@news.hgc.com.hk>,
sam <samwun@hgcbroadband.com> wrote:
>> system("/sbin/mount -t cd9660 /dev/acd0 /cdrom");
>> or
>> system("/sbin/mount /cdrom");
>>
>> but it appeared failed to mount to the cdrom.
>> I have two commands executed manually, the cdrom is mountable.
>
>May be this is the reason:
># /bin/sh -c "/sbin/mount /cdrom"
>cd9660: /dev/acd0: No such file or directory
Usually you don't mount acd0 but acd0c. This might be the
cause of the error. But you get "no such file or directory"
which means acd0c does not exist. Is this right?
As to your first question, normally only root can mount
the cdrom. So the program that does the system() will need
to be run by root as well (or be setuid root).
What commands do you use normally to mount the cd-rom?
Arnoud
-- Arnoud Engelfriet, Dutch patent attorney - Speaking only for myself Patents, copyright and IPR explained for techies: http://www.iusmentis.com/
- Next message: sam: "Re: mounting cdrom within function system()"
- Previous message: Eric Masson: "Re: USB to serial cable"
- In reply to: sam: "Re: mounting cdrom within function system()"
- Next in thread: sam: "Re: mounting cdrom within function system()"
- Reply: sam: "Re: mounting cdrom within function system()"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|