Problem with write access on fs-qnx4 in a embedded system

Hi all,

I’m doing some initial tests with embedded systems, is there any special configuration for enable write access in the filesystem?

Here’s the picture:
I want an embedded system that configure the Network and i will use the qnx4 filesystem. When i try to initialize the nfsd daemon I got a error with the portmap.

When I try to do a simple cp test ttt I got an error (cannot open destination file) or (function not implemented)…

Here’s a piece of my build file:


[+script] startup-script = {

devb-eide cam quiet blk auto=partition eide dma,ioport=1f0 rw &
devc-pty &
pipe &
display_msg “Inicializacao nfsd”
nfsd &
display_msg nfsd ok
devc-con -n2 &
reopen /dev/con1
[+session] esh &
reopen /dev/con2
[+session] esh &
ad_conv4
}

[type=link] /usr/lib/ldqnx.so.2=/proc/boot/libc.so
[type=link] /usr/lib/libcam.so.2=/proc/boot/libcam.so.2


[perms=+r,+x]
/lib/dll/devn-sis9.so
npm-tcpip.so
libc.so
fpemu.so
libsocket.so
libcam.so
io-blk.so
cam-disk.so
fs-qnx4.so

[data=copy]
[perms=+r,+x]
devc-con
devc-ser8250
devb-eide
io-net
pipe
devc-pty
pdebug
fs-nfs2
nfsd

Thanx for the help.

Start portmap before you start nfsd. Also make sure you have an
/etc/exports file.

dB


Leandro Colen wrote, ca. Thu, 20 Mar 2003 14:45:45 -0300:

Hi all,

I’m doing some initial tests with embedded systems, is there any special configuration for enable write access in the filesystem?

Here’s the picture:
I want an embedded system that configure the Network and i will use the qnx4 filesystem. When i try to initialize the nfsd daemon I got a error with the portmap.

When I try to do a simple cp test ttt I got an error (cannot open destination file) or (function not implemented)…

Here’s a piece of my build file:


[+script] startup-script = {

devb-eide cam quiet blk auto=partition eide dma,ioport=1f0 rw &
devc-pty &
pipe &
display_msg “Inicializacao nfsd”
nfsd &
display_msg nfsd ok
devc-con -n2 &
reopen /dev/con1
[+session] esh &
reopen /dev/con2
[+session] esh &
ad_conv4
}

[type=link] /usr/lib/ldqnx.so.2=/proc/boot/libc.so
[type=link] /usr/lib/libcam.so.2=/proc/boot/libcam.so.2


[perms=+r,+x]
/lib/dll/devn-sis9.so
npm-tcpip.so
libc.so
fpemu.so
libsocket.so
libcam.so
io-blk.so
cam-disk.so
fs-qnx4.so

[data=copy]
[perms=+r,+x]
devc-con
devc-ser8250
devb-eide
io-net
pipe
devc-pty
pdebug
fs-nfs2
nfsd

Thanx for the help.

Ok, this solve the problem with the nfsd error, but seems that I still have no write access.

the right error message:
Can’t open destination file. (xxxxxx) No such file or directory.

The same problem happens when a program try to create a file.



Previously, David Bacon wrote in qdn.public.qnxrtp.embedded:

Start portmap before you start nfsd. Also make sure you have an
/etc/exports file.

dB


Leandro Colen wrote, ca. Thu, 20 Mar 2003 14:45:45 -0300:

Hi all,

I’m doing some initial tests with embedded systems, is there any special configuration for enable write access in the filesystem?

Here’s the picture:
I want an embedded system that configure the Network and i will use the qnx4 filesystem. When i try to initialize the nfsd daemon I got a error with the portmap.

When I try to do a simple cp test ttt I got an error (cannot open destination file) or (function not implemented)…

Here’s a piece of my build file:


[+script] startup-script = {

devb-eide cam quiet blk auto=partition eide dma,ioport=1f0 rw &
devc-pty &
pipe &
display_msg “Inicializacao nfsd”
nfsd &
display_msg nfsd ok
devc-con -n2 &
reopen /dev/con1
[+session] esh &
reopen /dev/con2
[+session] esh &
ad_conv4
}

[type=link] /usr/lib/ldqnx.so.2=/proc/boot/libc.so
[type=link] /usr/lib/libcam.so.2=/proc/boot/libcam.so.2


[perms=+r,+x]
/lib/dll/devn-sis9.so
npm-tcpip.so
libc.so
fpemu.so
libsocket.so
libcam.so
io-blk.so
cam-disk.so
fs-qnx4.so

[data=copy]
[perms=+r,+x]
devc-con
devc-ser8250
devb-eide
io-net
pipe
devc-pty
pdebug
fs-nfs2
nfsd

Thanx for the help.

Need more info - what did you put in the /etc/exports file,
and how are you mounting the directory you want to write to?

dB


Leandro Colen wrote, ca. Thu, 20 Mar 2003 15:41:30 -0300:

Ok, this solve the problem with the nfsd error, but seems that I still have no write access.

the right error message:
Can’t open destination file. (xxxxxx) No such file or directory.

The same problem happens when a program try to create a file.



Previously, David Bacon wrote in qdn.public.qnxrtp.embedded:

Start portmap before you start nfsd. Also make sure you have an
/etc/exports file.

dB


Leandro Colen wrote, ca. Thu, 20 Mar 2003 14:45:45 -0300:

Hi all,

I’m doing some initial tests with embedded systems, is there any special configuration for enable write access in the filesystem?

Here’s the picture:
I want an embedded system that configure the Network and i will use the qnx4 filesystem. When i try to initialize the nfsd daemon I got a error with the portmap.

When I try to do a simple cp test ttt I got an error (cannot open destination file) or (function not implemented)…

Here’s a piece of my build file:


[+script] startup-script = {

devb-eide cam quiet blk auto=partition eide dma,ioport=1f0 rw &
devc-pty &
pipe &
display_msg “Inicializacao nfsd”
nfsd &
display_msg nfsd ok
devc-con -n2 &
reopen /dev/con1
[+session] esh &
reopen /dev/con2
[+session] esh &
ad_conv4
}

[type=link] /usr/lib/ldqnx.so.2=/proc/boot/libc.so
[type=link] /usr/lib/libcam.so.2=/proc/boot/libcam.so.2


[perms=+r,+x]
/lib/dll/devn-sis9.so
npm-tcpip.so
libc.so
fpemu.so
libsocket.so
libcam.so
io-blk.so
cam-disk.so
fs-qnx4.so

[data=copy]
[perms=+r,+x]
devc-con
devc-ser8250
devb-eide
io-net
pipe
devc-pty
pdebug
fs-nfs2
nfsd

Thanx for the help.

I’m trying to write in any directory. Not only in the exported directory…

I have a program that read some data provided from a Data Acquisition hardware and save the data every 5 minutes.

When the program tryies to open the file for write, the error occurs.

The nfs export will be used only to exchange the files between the QNX and other machine running Linux.

Right now I can’t open a file for write

Here’s my full buildfile (is only a test buildfile, so a lot of things will be removed in the future)

agv.bld

[virtual=x86,bios +compress] boot = {
startup-bios
PATH=/proc/boot:/bin:./ procnto
LD_LIBRARY_PATH=/lib:/proc/boot
procnto
}

[+script] startup-script = {

Seedres

seedres

Inictialize pci

pci-bios &
waitfor /dev/pci

TCP/IP

io-net -dsis9 -ptcpip
waitfor /dev/socket
dhcp.client

ifconfig en0 192.168.2.7 netmask 255.255.0.0

route add default 192.168.0.1

EIDE

devb-eide cam quiet blk auto=partition eide rw &
devc-pty &
pipe &

NFSD

portmap &
nfsd &

devc-con -n2 &
reopen /dev/con2
[+session] esh &
reopen /dev/con1
[+session] esh &
}

[type=link] /usr/lib/ldqnx.so.2=/proc/boot/libc.so
[type=link] /usr/lib/libcam.so.2=/proc/boot/libcam.so.2


[perms=+r,+x]
/lib/dll/devn-sis9.so
npm-tcpip.so
libc.so
fpemu.so
libsocket.so
libcam.so
io-blk.so
cam-disk.so
fs-qnx4.so
librpc.so.2

[data=copy]
[perms=+r,+x]
slogger
devc-con
devc-ser8250
devb-eide
io-net
pipe
devc-pty
pdebug
fs-nfs2
nfsd
stty
esh
ls
ifconfig
pidin
dhcp.client
slay
shutdown
cp
pci-bios
seedres
route
/root/dt2801/ad_conv4
portmap
showmount
vi
cat


/etc/exports = {
/tmp
}

/tmp/test = {
thraaaash
}

/lib/test = {
thrash
}

So I gather you are trying to do the mount from Linux.
Could you please show the mount command you are using.

dB


Leandro Colen wrote, ca. Thu, 20 Mar 2003 16:09:24 -0300:

I’m trying to write in any directory. Not only in the exported directory…

I have a program that read some data provided from a Data Acquisition hardware and save the data every 5 minutes.

When the program tryies to open the file for write, the error occurs.

The nfs export will be used only to exchange the files between the QNX and other machine running Linux.

Right now I can’t open a file for write

Here’s my full buildfile (is only a test buildfile, so a lot of things will be removed in the future)

agv.bld

[virtual=x86,bios +compress] boot = {
startup-bios
PATH=/proc/boot:/bin:./ procnto
LD_LIBRARY_PATH=/lib:/proc/boot
procnto
}

[+script] startup-script = {

Seedres

seedres

Inictialize pci

pci-bios &
waitfor /dev/pci

TCP/IP

io-net -dsis9 -ptcpip
waitfor /dev/socket
dhcp.client

ifconfig en0 192.168.2.7 netmask 255.255.0.0

route add default 192.168.0.1

EIDE

devb-eide cam quiet blk auto=partition eide rw &
devc-pty &
pipe &

NFSD

portmap &
nfsd &

devc-con -n2 &
reopen /dev/con2
[+session] esh &
reopen /dev/con1
[+session] esh &
}

[type=link] /usr/lib/ldqnx.so.2=/proc/boot/libc.so
[type=link] /usr/lib/libcam.so.2=/proc/boot/libcam.so.2


[perms=+r,+x]
/lib/dll/devn-sis9.so
npm-tcpip.so
libc.so
fpemu.so
libsocket.so
libcam.so
io-blk.so
cam-disk.so
fs-qnx4.so
librpc.so.2

[data=copy]
[perms=+r,+x]
slogger
devc-con
devc-ser8250
devb-eide
io-net
pipe
devc-pty
pdebug
fs-nfs2
nfsd
stty
esh
ls
ifconfig
pidin
dhcp.client
slay
shutdown
cp
pci-bios
seedres
route
/root/dt2801/ad_conv4
portmap
showmount
vi
cat


/etc/exports = {
/tmp
}

/tmp/test = {
thraaaash
}

/lib/test = {
thrash
}

The mount isn’t the problem.

I have a program on the QNX machine that will gather the data from the data aquisition card. This data will be shared via nfs.

My program in the QNX machine can’t open the file for writing. I’m trying to create the file in any directory in the QNX. The problem is on the QNX filesystem.

the problem is on the QNX machine. The nfs will be the problem as soon as I solve the create file problem. :slight_smile:





Previously, David Bacon wrote in qdn.public.qnxrtp.embedded:

So I gather you are trying to do the mount from Linux.
Could you please show the mount command you are using.

dB


Leandro Colen wrote, ca. Thu, 20 Mar 2003 16:09:24 -0300:

I’m trying to write in any directory. Not only in the exported directory…

I have a program that read some data provided from a Data Acquisition hardware and save the data every 5 minutes.

When the program tryies to open the file for write, the error occurs.

The nfs export will be used only to exchange the files between the QNX and other machine running Linux.

Right now I can’t open a file for write

Here’s my full buildfile (is only a test buildfile, so a lot of things will be removed in the future)

agv.bld

[virtual=x86,bios +compress] boot = {
startup-bios
PATH=/proc/boot:/bin:./ procnto
LD_LIBRARY_PATH=/lib:/proc/boot
procnto
}

[+script] startup-script = {

Seedres

seedres

Inictialize pci

pci-bios &
waitfor /dev/pci

TCP/IP

io-net -dsis9 -ptcpip
waitfor /dev/socket
dhcp.client

ifconfig en0 192.168.2.7 netmask 255.255.0.0

route add default 192.168.0.1

EIDE

devb-eide cam quiet blk auto=partition eide rw &
devc-pty &
pipe &

NFSD

portmap &
nfsd &

devc-con -n2 &
reopen /dev/con2
[+session] esh &
reopen /dev/con1
[+session] esh &
}

[type=link] /usr/lib/ldqnx.so.2=/proc/boot/libc.so
[type=link] /usr/lib/libcam.so.2=/proc/boot/libcam.so.2


[perms=+r,+x]
/lib/dll/devn-sis9.so
npm-tcpip.so
libc.so
fpemu.so
libsocket.so
libcam.so
io-blk.so
cam-disk.so
fs-qnx4.so
librpc.so.2

[data=copy]
[perms=+r,+x]
slogger
devc-con
devc-ser8250
devb-eide
io-net
pipe
devc-pty
pdebug
fs-nfs2
nfsd
stty
esh
ls
ifconfig
pidin
dhcp.client
slay
shutdown
cp
pci-bios
seedres
route
/root/dt2801/ad_conv4
portmap
showmount
vi
cat


/etc/exports = {
/tmp
}

/tmp/test = {
thraaaash
}

/lib/test = {
thrash
}

Adam Mallory <amallory@qnx.com> wrote:

You can’t copy into the /proc/boot directory (or anywhere else except
/dev/shmem, if that is what you’re doing - and that’s not a real filesystem
anyways). If you want a full filesystem in RAM you’ll need to run either
devb-ram or devf-ram.

Or, if you want one with source, www.parse.com/free/ramdisk.html

Cheers,
-RK

-Adam

Leandro Colen <> lcrocha@yahoo.com> > wrote in message
news:Voyager.030321112546.524308A@gear10…
The mount isn’t the problem.

I have a program on the QNX machine that will gather the data from the
data aquisition card. This data will be shared via nfs.

My program in the QNX machine can’t open the file for writing. I’m trying
to create the file in any directory in the QNX. The problem is on the QNX
filesystem.

the problem is on the QNX machine. The nfs will be the problem as soon as
I solve the create file problem. > :slight_smile:





Previously, David Bacon wrote in qdn.public.qnxrtp.embedded:
So I gather you are trying to do the mount from Linux.
Could you please show the mount command you are using.

dB


Leandro Colen wrote, ca. Thu, 20 Mar 2003 16:09:24 -0300:

I’m trying to write in any directory. Not only in the exported
directory…

I have a program that read some data provided from a Data Acquisition
hardware and save the data every 5 minutes.

When the program tryies to open the file for write, the error occurs.

The nfs export will be used only to exchange the files between the QNX
and other machine running Linux.

Right now I can’t open a file for write

Here’s my full buildfile (is only a test buildfile, so a lot of things
will be removed in the future)

agv.bld

[virtual=x86,bios +compress] boot = {
startup-bios
PATH=/proc/boot:/bin:./ procnto
LD_LIBRARY_PATH=/lib:/proc/boot
procnto
}

[+script] startup-script = {

Seedres

seedres

Inictialize pci

pci-bios &
waitfor /dev/pci

TCP/IP

io-net -dsis9 -ptcpip
waitfor /dev/socket
dhcp.client

ifconfig en0 192.168.2.7 netmask 255.255.0.0

route add default 192.168.0.1

EIDE

devb-eide cam quiet blk auto=partition eide rw &
devc-pty &
pipe &

NFSD

portmap &
nfsd &

devc-con -n2 &
reopen /dev/con2
[+session] esh &
reopen /dev/con1
[+session] esh &
}

[type=link] /usr/lib/ldqnx.so.2=/proc/boot/libc.so
[type=link] /usr/lib/libcam.so.2=/proc/boot/libcam.so.2


[perms=+r,+x]
/lib/dll/devn-sis9.so
npm-tcpip.so
libc.so
fpemu.so
libsocket.so
libcam.so
io-blk.so
cam-disk.so
fs-qnx4.so
librpc.so.2

[data=copy]
[perms=+r,+x]
slogger
devc-con
devc-ser8250
devb-eide
io-net
pipe
devc-pty
pdebug
fs-nfs2
nfsd
stty
esh
ls
ifconfig
pidin
dhcp.client
slay
shutdown
cp
pci-bios
seedres
route
/root/dt2801/ad_conv4
portmap
showmount
vi
cat


/etc/exports = {
/tmp
}

/tmp/test = {
thraaaash
}

/lib/test = {
thrash
}


Robert Krten, PARSE Software Devices +1 613 599 8316.
Realtime Systems Architecture, Books, Video-based and Instructor-led
Training and Consulting at www.parse.com.
Email my initials at parse dot com.

You can’t copy into the /proc/boot directory (or anywhere else except
/dev/shmem, if that is what you’re doing - and that’s not a real filesystem
anyways). If you want a full filesystem in RAM you’ll need to run either
devb-ram or devf-ram.

-Adam

Leandro Colen <lcrocha@yahoo.com> wrote in message
news:Voyager.030321112546.524308A@gear10…

The mount isn’t the problem.

I have a program on the QNX machine that will gather the data from the
data aquisition card. This data will be shared via nfs.

My program in the QNX machine can’t open the file for writing. I’m trying
to create the file in any directory in the QNX. The problem is on the QNX

filesystem.

the problem is on the QNX machine. The nfs will be the problem as soon as
I solve the create file problem. > :slight_smile:





Previously, David Bacon wrote in qdn.public.qnxrtp.embedded:
So I gather you are trying to do the mount from Linux.
Could you please show the mount command you are using.

dB


Leandro Colen wrote, ca. Thu, 20 Mar 2003 16:09:24 -0300:

I’m trying to write in any directory. Not only in the exported
directory…

I have a program that read some data provided from a Data Acquisition
hardware and save the data every 5 minutes.

When the program tryies to open the file for write, the error occurs.

The nfs export will be used only to exchange the files between the QNX
and other machine running Linux.

Right now I can’t open a file for write

Here’s my full buildfile (is only a test buildfile, so a lot of things
will be removed in the future)

agv.bld

[virtual=x86,bios +compress] boot = {
startup-bios
PATH=/proc/boot:/bin:./ procnto
LD_LIBRARY_PATH=/lib:/proc/boot
procnto
}

[+script] startup-script = {

Seedres

seedres

Inictialize pci

pci-bios &
waitfor /dev/pci

TCP/IP

io-net -dsis9 -ptcpip
waitfor /dev/socket
dhcp.client

ifconfig en0 192.168.2.7 netmask 255.255.0.0

route add default 192.168.0.1

EIDE

devb-eide cam quiet blk auto=partition eide rw &
devc-pty &
pipe &

NFSD

portmap &
nfsd &

devc-con -n2 &
reopen /dev/con2
[+session] esh &
reopen /dev/con1
[+session] esh &
}

[type=link] /usr/lib/ldqnx.so.2=/proc/boot/libc.so
[type=link] /usr/lib/libcam.so.2=/proc/boot/libcam.so.2


[perms=+r,+x]
/lib/dll/devn-sis9.so
npm-tcpip.so
libc.so
fpemu.so
libsocket.so
libcam.so
io-blk.so
cam-disk.so
fs-qnx4.so
librpc.so.2

[data=copy]
[perms=+r,+x]
slogger
devc-con
devc-ser8250
devb-eide
io-net
pipe
devc-pty
pdebug
fs-nfs2
nfsd
stty
esh
ls
ifconfig
pidin
dhcp.client
slay
shutdown
cp
pci-bios
seedres
route
/root/dt2801/ad_conv4
portmap
showmount
vi
cat


/etc/exports = {
/tmp
}

/tmp/test = {
thraaaash
}

/lib/test = {
thrash
}

Leandro, your devb-eide command looks okay (except that I
don’t think the “eide” part takes a “rw” option - that
belongs with the “blk” part if you specify it at all), so
assuming you have a properly partitioned and initialized
hard drive, you should be able to see those partitions as
writeable filesystem subtrees under /fs/, as a result of
the “auto=partition” option you (correctly) already put
after “blk”.

All the rest of your filename space, however, except for
the part under /dev/shmem, will, as Adam says, be read-only.
(You don’t have to live with the writeable space all living
under /fs, of course - that’s just the choice auto=partition
makes - you can mount your partitions wherever you like if
you don’t use auto=partition or if you umount them from /fs
before remounting them elsewhere.)

dB


“Adam Mallory” wrote, ca. Fri, 21 Mar 2003 10:52:58 -0500:


You can’t copy into the /proc/boot directory (or anywhere else except
/dev/shmem, if that is what you’re doing - and that’s not a real filesystem
anyways). If you want a full filesystem in RAM you’ll need to run either
devb-ram or devf-ram.

-Adam

Leandro Colen <lcrocha@yahoo.com> wrote in message
news:Voyager.030321112546.524308A@gear10…

The mount isn’t the problem.

I have a program on the QNX machine that will gather the data from the
data aquisition card. This data will be shared via nfs.

My program in the QNX machine can’t open the file for writing. I’m trying
to create the file in any directory in the QNX. The problem is on the QNX

filesystem.

the problem is on the QNX machine. The nfs will be the problem as soon as
I solve the create file problem. > :slight_smile:





Previously, David Bacon wrote in qdn.public.qnxrtp.embedded:
So I gather you are trying to do the mount from Linux.
Could you please show the mount command you are using.

dB


Leandro Colen wrote, ca. Thu, 20 Mar 2003 16:09:24 -0300:

I’m trying to write in any directory. Not only in the exported
directory…

I have a program that read some data provided from a Data Acquisition
hardware and save the data every 5 minutes.

When the program tryies to open the file for write, the error occurs.

The nfs export will be used only to exchange the files between the QNX
and other machine running Linux.

Right now I can’t open a file for write

Here’s my full buildfile (is only a test buildfile, so a lot of things
will be removed in the future)

agv.bld

[virtual=x86,bios +compress] boot = {
startup-bios
PATH=/proc/boot:/bin:./ procnto
LD_LIBRARY_PATH=/lib:/proc/boot
procnto
}

[+script] startup-script = {

Seedres

seedres

Inictialize pci

pci-bios &
waitfor /dev/pci

TCP/IP

io-net -dsis9 -ptcpip
waitfor /dev/socket
dhcp.client

ifconfig en0 192.168.2.7 netmask 255.255.0.0

route add default 192.168.0.1

EIDE

devb-eide cam quiet blk auto=partition eide rw &
devc-pty &
pipe &

NFSD

portmap &
nfsd &

devc-con -n2 &
reopen /dev/con2
[+session] esh &
reopen /dev/con1
[+session] esh &
}

[type=link] /usr/lib/ldqnx.so.2=/proc/boot/libc.so
[type=link] /usr/lib/libcam.so.2=/proc/boot/libcam.so.2


[perms=+r,+x]
/lib/dll/devn-sis9.so
npm-tcpip.so
libc.so
fpemu.so
libsocket.so
libcam.so
io-blk.so
cam-disk.so
fs-qnx4.so
librpc.so.2

[data=copy]
[perms=+r,+x]
slogger
devc-con
devc-ser8250
devb-eide
io-net
pipe
devc-pty
pdebug
fs-nfs2
nfsd
stty
esh
ls
ifconfig
pidin
dhcp.client
slay
shutdown
cp
pci-bios
seedres
route
/root/dt2801/ad_conv4
portmap
showmount
vi
cat


/etc/exports = {
/tmp
}

/tmp/test = {
thraaaash
}

/lib/test = {
thrash
}