why I can't get file from FTP?

Dear all
I want to create a QNX6.3 small image in the IDE Flash HD(for 1G space)
now, I can statup on the Flash HD . It has same function. example: telnet ,remote debug(qconn) , ftp…
I can telnet and remote debug link to the HD, but I can’t ftp to the HD.
I don’t know the question. If People know ,please tell me . Thanks.
flow chart is:

mkifs myfile.build myimage.ifs
dinit -h -R -f myimage.ifs /dev/hd1
dloader /dev/hd1 /usr/qnx630/target/qnx6/x86/boot/sys/ipl-diskpc2

now, I can login to the FTP , but I can’t “get” and “put” the file.
Error mesaage:

local: file.c remote: file.c
ftp: local : file.c: Read-only file system

If everyone want to read the image file , I can put it!

The image will be Read only filesystem… hence you cannot put into it…
YOu can try in /dev/shmem-> tmp folder .
Or include the filesystem & ide driver… mount the filesystem & you can do all Filesystem operations on it…

Dear New Member
thank you! now I can put file in the FTP. This is my image:

[virtual=x86,bios +compress] .bootstrap = {
startup-bios
PATH=/proc/boot procnto -smp
}
[+script] startup-script = {
display_msg “Welcome to QNX Neutrino on an PC compatible BIOS system for SMP”
seedres
pci-bios &
waitfor /dev/pci
# Start 1 keyboard console
devc-con -n8 &
# Start serial A driver
waitfor /dev/con1
reopen /dev/con1
devc-ser8250 -e -b38400
waitfor /dev/ser1
pipe
touch /tmp/syslog
syslogd
devc-pty

 display_msg "Start network interface"
#io-net -dne2000  ioport=0x340,irq=5 -pttcpip -p qnet if=en0:10.153.29.101:255.255.255.0
 io-net -d ne2000  ioport=0x340,irq=0x5 -p tcpip  
 waitfor /dev/socket 30 
 ifconfig en0 10.153.29.101 netmask 255.255.255.0  
#io-net -ppppmgr -pttcpip
#waitfor /dev/io-net/ip_ppp
 waitfor /dev/ptyp0 4
qconn port=8000
inetd &

qconn &
display_msg “Startup Finish”
[+session] PATH=/bin:/proc/boot /bin/sh &
}

Make /tmp point to the shared memory area…

[type=link] /tmp=/dev/shmem

Programs require the runtime linker (ldqnx.so) to be at

a fixed location

[type=link] /usr/lib/ldqnx.so.2=/proc/boot/libc.so
[type=link] /bin/sh=/bin/ksh

[type=link] /root=/root

We use the “c” shared lib (which also contains the

runtime linker)

libc.so
libm.so
libsocket.so
npm-ttcpip.so
npm-pppmgr.so

devn-ne2000.so
npm-tcpip.so

The files above this line can be shared by multiple

processes

[data=c]
devc-con
devc-ser8250
devc-pty
pci-bios
seedres
pipe
io-net
/bin/echo=echo
/bin/stty=stty
tail
pci
chat
ifconfig
ping
syslogd
touch
ls
qconn
pidin
pdebug
shutdown
ftp
tftp
mkdir
#./modem_ans_ppp.sh

#Services (telnetd etc) config
inetd
/usr/sbin/telnetd=telnetd
/usr/sbin/tftpd=tftpd
/usr/sbin/ftpd=ftpd
/usr/sbin/pppd=pppd
/bin/login=login
/bin/ksh=ksh

/etc/ppp/chap-secrets = {

Client Server Secret Addrs

#########################################

  •       *           "password"  *
    

}
/etc/syslog.conf = {
. /tmp/syslog
}

Inetd config Files

/etc/services= /etc/services
/etc/protocols= /etc/protocols
/etc/termcap= /etc/termcap
/etc/passwd= /etc/passwd
/etc/default/login= /etc/default/login
/etc/resolv.conf= /etc/resolv.conf
#/etc/shadow = /etc/shadow

/etc/inetd.conf = {
telnet stream tcp nowait root /usr/sbin/telnetd in.telnetd
#tftp dgram udp wait root /usr/sbin/tftpd in.tftpd
ftp stream tcp nowait root /usr/sbin/ftpd in.ftpd
-l
}

/etc/hosts = {
127.1 localhost.localdomain localhost
10.99.99.1 server server
10.99.99.2 client client
}

now I have two guesses:

  1. “dinit” command . I must set HD to R/W mode but I can’t understand how to set.
    who help me?
  2. I loss the FTP set in the image . but I can’t find it. please help me

Thanks.

1.To make HD R/W there is an option in io-blk.so… which you can give while running teh devb-eide driver …Check dev-eide & io-blk.so in utilities refernce for the options

2.you need give correct path of ftpd in inetd.conf file…

Dear all
I write the image , but it can’t still get the file on the ftp.
How can I to write?

Error mesaage:

local: file.c remote: file.c
ftp: local : file.c: Read-only file system

[virtual=x86,bios +compress] .bootstrap = {
startup-bios
PATH=/proc/boot procnto -smp
}
[+script] startup-script = {
display_msg “Welcome to QNX Neutrino on an PC compatible BIOS system for SMP”
seedres
pci-bios &
waitfor /dev/pci
# Start 1 keyboard console
devc-con -n8 &
# Start serial A driver
waitfor /dev/con1
reopen /dev/con1
devc-ser8250 -e -b38400
waitfor /dev/ser1
pipe
touch /tmp/syslog
syslogd
devc-pty

 display_msg "Start network interface"
#io-net -dne2000  ioport=0x340,irq=5 -pttcpip -p qnet if=en0:10.153.29.101:255.255.255.0
 io-net -d ne2000  ioport=0x340,irq=0x5 -p tcpip  
 waitfor /dev/socket 30 
# ifconfig en0 10.153.29.101 netmask 255.255.255.0  
#io-net -ppppmgr -pttcpip
#waitfor /dev/io-net/ip_ppp
 waitfor /dev/ptyp0 4
qconn port=8000
inetd &

qconn &
display_msg “Startup Finish”
[+session] PATH=/bin:/proc/boot /bin/sh &
}

Make /tmp point to the shared memory area…

[type=link] /tmp=/dev/shmem

Programs require the runtime linker (ldqnx.so) to be at

a fixed location

[type=link] /usr/lib/ldqnx.so.2=/proc/boot/libc.so
[type=link] /bin/sh=/bin/ksh

We use the “c” shared lib (which also contains the

runtime linker)

libc.so
libm.so
libsocket.so
npm-ttcpip.so
npm-pppmgr.so

devn-ne2000.so
npm-tcpip.so
devn-i82544.so

io-blk.so

The files above this line can be shared by multiple

processes

[data=c]
devc-con
devc-ser8250
devb-eide
devc-pty
pci-bios
seedres
pipe
io-net
/bin/echo=echo
/bin/stty=stty
tail
pci
chat
ifconfig
ping
syslogd
touch
ls
qconn
pidin
pdebug
slay
ftp
shutdown
#./modem_ans_ppp.sh

#Services (telnetd etc) config
inetd
/usr/sbin/telnetd=telnetd
/usr/sbin/tftpd=tftpd
/usr/sbin/pppd=pppd
/bin/login=login
/bin/ksh=ksh

/etc/ppp/chap-secrets = {

Client Server Secret Addrs

#########################################

  •       *           "password"  *
    

}
/etc/syslog.conf = {
. /tmp/syslog
}

Inetd config Files

/etc/services= /etc/services
/etc/protocols= /etc/protocols
/etc/termcap= /etc/termcap
/etc/passwd= /etc/passwd
/etc/default/login= /etc/default/login
/etc/resolv.conf= /etc/resolv.conf
#/etc/shadow = /etc/shadow

/etc/inetd.conf = {
telnet stream tcp nowait root /usr/sbin/telnetd in.telnetd
#tftp dgram udp wait root /usr/sbin/tftpd in.tftpd
ftp stream tcp nowait root /usr/sbin/tftpd in.tftpd -l

}

/etc/hosts = {
127.1 localhost.localdomain localhost
10.99.99.1 server server
10.99.99.2 client client
}

/etc/service={
ftp 21/tcp
telnet 23/top
syslog 514/udp
}

As informed earlier you can only write into /tmp folder
Go to /tmp & then write into it.

If you want to write to the filesystem in the Harddisk… You need to run the devb-eide driver… & you need to mount the filesystem… for that you need to include
devb-eide
io-blk.so
fs-qnx4.so
cam-disk.so
libcam.so
mount
Then in the script you need to run…

devb-eide &
waitfor /dev/hd0t79
mount /dev/hd0t79 /
Then you cna write to any folders of in the filesystem…

Dear member
I can use the FTP function → “put” and "get " in the any path.
but I still have a question. now my image is ftp or tftp function.
Who can tell me? Because their protocol is different. If I want to use the ftp protocol , how can I to write the image?

Thanks.

my image :

[virtual=x86,bios +compress] .bootstrap = {
startup-bios
PATH=/proc/boot procnto -smp
}

[+script] startup-script = {
display_msg “Welcome to QNX Neutrino on an PC compatible BIOS system for SMP”
seedres
pci-bios &
waitfor /dev/pci
# Start 1 keyboard console
devc-con -n8 &
# Start serial A driver
waitfor /dev/con1
reopen /dev/con1
devc-ser8250 -e -b38400
waitfor /dev/ser1
pipe
touch /tmp/syslog
syslogd
devb-eide &
waitfor /dev/hd0
mount /dev/hd0 /
devc-pty

display_msg "Start network interface"
#io-net -dne2000  ioport=0x340,irq=5 -pttcpip -p qnet if=en0:10.153.29.101:255.255.255.0
# io-net -d ne2000  ioport=0x340,irq=0x5 -p tcpip  
waitfor /dev/socket 30 
#ifconfig en0 10.153.29.101 netmask 255.255.255.0  
#io-net -ppppmgr -pttcpip
#waitfor /dev/io-net/ip_ppp
waitfor /dev/ptyp0 4
qconn port=8000
inetd &

qconn &
display_msg "Startup Finish"
[+session] PATH=/bin:/proc/boot /bin/sh &

}

Make /tmp point to the shared memory area…

[type=link] /tmp=/dev/shmem

Programs require the runtime linker (ldqnx.so) to be at

a fixed location

[type=link] /usr/lib/ldqnx.so.2=/proc/boot/libc.so
[type=link] /bin/sh=/bin/ksh

We use the “c” shared lib (which also contains the

runtime linker)

libc.so
libm.so
libsocket.so
npm-ttcpip.so
npm-pppmgr.so

devn-ne2000.so
npm-tcpip.so
devn-i82544.so
io-blk.so
fs-qnx4.so
cam-disk.so
libcam.so

The files above this line can be shared by multiple

processes

[data=c]
devc-con
devc-ser8250
devc-pty
pci-bios
seedres
pipe
io-net
/bin/echo=echo
/bin/stty=stty
tail
pci
chat
ifconfig
ping
syslogd
touch
ls
qconn
pidin
pdebug
slay
mount
devb-eide
ftp
inetd
shutdown
#./modem_ans_ppp.sh

#Services (telnetd etc) config

/usr/sbin/telnetd=telnetd
/usr/sbin/tftpd=tftpd
/usr/sbin/pppd=pppd
/bin/login=login
/bin/ksh=ksh

/etc/ppp/chap-secrets = {

Client Server Secret Addrs

#########################################

  •       *           "password"  *
    

}
/etc/syslog.conf = {
. /tmp/syslog
. /…/… }

Inetd config Files

/etc/services= /etc/services
/etc/protocols= /etc/protocols
/etc/termcap= /etc/termcap
/etc/passwd= /etc/passwd
/etc/default/login= /etc/default/login
/etc/resolv.conf= /etc/resolv.conf
#/etc/shadow = /etc/shadow

/etc/inetd.conf = {
telnet stream tcp nowait root /usr/sbin/telnetd in.telnetd
#tftp dgram udp wait root /usr/sbin/tftpd in.tftpd
tftp stream tcp nowait root /usr/sbin/ftpd in.tftpd
}

/etc/hosts = {
127.1 localhost.localdomain localhost
10.99.99.1 server server
10.99.99.2 client client
}