How to change symbolic links via script

Hello,

the install routine puts automatically the servername "SERVER" in the symlink like:

hello.txt --> /SERVER/usr/lpp/hello.txt
world.txt --> /SERVER/usr/lpp/world.txt

... but i need to change this symlinks (without servername) to:

hello.txt --> /usr/lpp/hello.txt
world.txt --> /usr/lpp/world.txt

Thx for help!

I'm not sure if I understood your problem but have tried this before?

ln -fs hello.txt /usr/lpp/hello.txt
ln -fs world.txt /usr/lpp/world.txt

I know about this command but the symlinks are in several subdirectories and must be changed recursively.

This should fix the issue at once:

ln -s / /SERVER