DSM-G600, DNS-3xx and NSA-220 Hack Forum

Unfortunately no one can be told what fun_plug is - you have to see it for yourself.

You are not logged in.

Announcement

#1 2011-02-27 13:17:47

mastervol
Member
Registered: 2008-09-06
Posts: 81

change linking path of binaries and libraries

hey there,

my current problem is as follows:

1)
i have a cron job which executes a script every hour.

2)
it runs a script which calls other bash commands on the usb mounted disk.

3)
the goal is to run the script without having the disk to spin up.

i moved all required binaries and libraries to the usb stick and changed the linking path of the binaries to the directory on the usb stick with chrpath (e.g. from /ffp/lib to /mnt/usb).
however i discovered that a lot of the libraries under /ffp/lib which i moved to the usb stick have the path to it's location hard coded.
that's the reason my harddrive spins up evertime the script is called.

so my question is:
how can i change theses paths in order for the harddrive not to spin up?
e.g. from /ffp/lib/ to /mnt/usb?

thx

/mnt/nzb:

Code:

ld-uClibc-0.9.29.so
ld-uClibc.so.0
libc.so.0
libcrypt.so.0
libcurl.so
libdl.so.0
libgcc_s.so.1
libhistory.so.5.2
libm.so.0
libncurses.so.5
libncurses.so.5.6
libpcre.so.0
libpthread.so.0
libreadline.so.5.2
libresolv.so.0
libsasl2.so.2
libuClibc-0.9.29.so
libxml2.so.2
libz.so.1

/mnt/usb/bin:

Code:

basename
bash
busybox
date
echo
getdhcp
ls
lsof
sleep
wc

Code:

root@323:/mnt/usb# ldd ./libc.so.0
ldd: can't open cache '/ffp/etc/ld.so.cache'
        ld-uClibc.so.0 => /ffp/lib/ld-uClibc.so.0 (0x40000000)
root@323:/mnt/nzb#

Last edited by mastervol (2011-02-27 13:20:08)


DNS-323     F/W: 1.06  H/W: ??  ffp: 0.5  Drives (normal mode): 1 x 1,5 TB Seagate SATA II ST31500341AS, 1 x 250 GB Western Digital SATA I

Offline

 

Board footer

Powered by PunBB
© Copyright 2002–2010 PunBB