[FreeNX-kNX] Suggested Diff for Fedora 8 nxloadconfig
Gregory Carter
gcarter at aesgi.com
Thu Mar 20 17:31:59 UTC 2008
Alastair Johnson wrote:
> On Wednesday 19 March 2008, Gregory Carter wrote:
>
>> I found that, the freenx server config that ships with Fedora 8, has
>> less than desirable default settings. These settings, tend to
>> malfunction depending on the package installation selected by the
>> administrator. I found, black screens on some servers, plain old
>> disconnect errors and a variety of connection problems like connection
>> loss with the default install.
>>
>> So, I have stripped all of the stuff that does not belong to Fedora 8
>> out of the nxloadconfig script. This will gurantee that the server has
>> the correct defaults under Fedora 8.
>>
>> The entire configuration for nx, is very bizarre in my opinion, due to
>> the fact configuration settings do not exist in a central file in a
>> directory under /etc.
>>
>
> The central file for the settings is /etc/nxserver/node.conf and there is a
> commented example /etc/nxserver/node.conf.sample provided by the fedora RPMs.
> nxloadconfig provides the application defaults which are overridden by
> node.conf. If freenx were compiled binaries rather than shell scripts then
> the settings in nxloadconfig would be in the binary. It is arguable that the
> fedora packagers should include a fedora-optimised node.conf instead of
> patching nxloadconfig. They do aim to update node.conf.sample so the defaults
> mentioned match their modified nxloadconfig though it doesn't always happen.
> Rick corrected mismatches I've reported in the past, but that was some time
> ago.
>
>
I am aware of the above facts you point out, nevertheless, nxloadconfig
could be placed under the same set of arguments as node.conf.
In my opinion, that would mean Fedora package engineers would have to
maintain two sets of configuration files for basically the same defaults
settings.
I think nxloadconfig should be rewritten to accept inputs from node.conf
and only do check logic based on distro.
So, for example, you would not see stuff like this in nxloadconfig:
COMMAND_FOOMATIC="/usr/bin/foomatic-ppdfile"
>> I almost feel like a Windows admin sometimes in dealing with this
>> software because, like Windows .ini files are usually spread out all
>> over the place with no rhyme or reason. What is needed is a new
>> packaging system for nx that makes the thing incredibly non windows
>> like. (i.e. organized under /etc )
>>
>> After exploring many of these difficulties in setting up a variety of
>> Fedora 8 NX systems on my remote and local network. I find that the
>> below diff, if applied to the nxloadconfig file after a fresh
>> installation of freenx, gurantees the nx server environment is properly
>> setup and will run with the defaults.
>>
>> Any feedback would be most welcome.
>>
>
> Comments inline below.
>
>
>> -gc
>>
>> 157c157
>> < COMMAND_FOOMATIC="/usr/lib/cups/driver/foomatic-ppdfile"
>> ---
>>
>> > COMMAND_FOOMATIC="/usr/bin/foomatic-ppdfile"
>>
>
> Looks fair for fedora 8.
>
>
>> 269,270d268
>> < { ! mywhich "$PATH_BIN/nxdesktop"; } >/dev/null 2>&1 &&
>> ENABLE_EXTERNAL_NXDESKTOP="1"
>> < { ! mywhich "$PATH_BIN/nxviewer"; } >/dev/null 2>&1 &&
>> ENABLE_EXTERNAL_NXVIEWER="1"
>>
>
> Why remove this? what problem does it cause?
>
>
It is not so much a problem as it is incorrect, and outputs useless
warnings, which can be almost just as bad.
>> 300c298
>> < [ -z "$APPLICATION_LIBRARY_PRELOAD" ] &&
>> APPLICATION_LIBRARY_PRELOAD="$APPLICATION_LIBRARY_PATH/libX11.so.6.2:$APPLI
>> CATION_LIBRARY_PATH/libXext.so.6.4:$APPLICATION_LIBRARY_PATH/libXcomp.so:$AP
>> PLICATION_LIBRARY_PATH/libXcompext.so:$APPLICATION_LIBRARY_PATH/libXrender.s
>> o.1.2" ---
>>
>> > [ -z "$APPLICATION_LIBRARY_PRELOAD" ] &&
>>
>> APPLICATION_LIBRARY_PRELOAD="$APPLICATION_LIBRARY_PATH/libX11.so.6.2"
>>
>
> Some of the version numbers don't match the files supplied by the fedora 8
> (well...f7 since f8 uses the f7 package) but isn't the answer to set the
> right version numbers rather than remove them?
>
> [ -z "$APPLICATION_LIBRARY_PRELOAD" ] &&
> APPLICATION_LIBRARY_PRELOAD="$APPLICATION_LIBRARY_PATH/libX11.so.6.2:
> $APPLICATION_LIBRARY_PATH/libXext.so.6.4:
> $APPLICATION_LIBRARY_PATH/libXcomp.so.2:
> $APPLICATION_LIBRARY_PATH/libXcompext.so.2:
> $APPLICATION_LIBRARY_PATH/libXrender.so.1.2" ---
>
>
These are again issuing warnings that do not make sense for Fedora. See
above comment.
>> 332,351d329
>> < if [ "ENABLE_EXTERNAL_NXDESKTOP" = "1" ]
>> < then
>> < [ ! mywhich "$COMMAND_RDESKTOP" >/dev/null 2>&1 ] && \
>> < WARNING="yes" && echo "Warning: Could not find
>> COMMAND_RDESKTOP=$COMMAND_RDESKTOP. RDP sessions won't work."
>> < else
>> < [ ! -x "$PATH_BIN/nxdesktop" ] && \
>> < WARNING="yes" && echo "Warning: Could not find
>> nxdesktop in $PATH_BIN. RDP sessions won't work."
>> < fi
>> <
>> < if [ "ENABLE_EXTERNAL_NXVIEWER" = "1" ]
>> < then
>> < [ ! mywhich "$COMMAND_VNCVIEWER" >/dev/null 2>&1 ] && \
>> < WARNING="yes" && echo "Warning: Could not find
>> COMMAND_VNCVIEWER=$COMMAND_VNCVIEWER. VNC sessions won't work."
>> < [ ! mywhich "$COMMAND_VNCPASSWD" >/dev/null 2>&1 ] && \
>> < WARNING="yes" && echo "Warning: Could not find
>> COMMAND_VNCPASSWD=$COMMAND_VNCPASSWD. VNC sessions won't work."
>> < else
>> < [ ! -x "$PATH_BIN/nxviewer" ] && \
>> < WARNING="yes" && echo "Warning: Could not find
>> nxviewer in $PATH_BIN. VNC sessions won't work."
>> < fi
>>
>
> This is just removing warnings about incorrectly set or unset options. Nothing
> is set here, and it's removing potentially useful debugging information. Why
> remove it? What problem does it cause?
>
>
Again, warnings that are useless and not relelvant to Fedora 8.
>> 499,504d476
>> < [ ! -x "$CUPS_IPP_BACKEND" ] && \
>> < WARNING="yes" && echo "Warning: \"$CUPS_IPP_BACKEND\" is
>> not executable." \
>> < && echo " Users will
>> not be able to enable printing."
>> < [ ! -x "$CUPS_BACKEND/smb" ] && \
>> < WARNING="yes" && echo "Warning: \"$CUPS_BACKEND/smb\" is
>> not executable." \
>> < && echo " Users will
>> not be able to enable printing."
>>
>
> More warnings removed - see above
>
>
Same same.
>> 531,533c503
>> < ! mywhich "$COMMAND_START_CDE" >/dev/null 2>&1 && \
>> < WARNING="yes" && echo "Warning: Invalid value
>> \"COMMAND_START_CDE=$COMMAND_START_CDE\"" \
>> < && echo " Users will
>> not be able to request a CDE session."
>> ---
>>
>
> More warnings removed - see above
>
>
Same same.
>> 539,542d508
>> < ! mywhich "$COMMAND_SMBMOUNT" >/dev/null 2>&1 && \
>> < WARNING="yes" && echo "Warning: Invalid value
>> \"COMMAND_SMBMOUNT=$COMMAND_SMBMOUNT\". You'll not be able to use SAMBA. "
>> < ! mywhich "$COMMAND_SMBUMOUNT" >/dev/null 2>&1 && \
>> < WARNING="yes" && echo "Warning: Invalid value
>> \"COMMAND_SMBUMOUNT=$COMMAND_SMBUMOUNT\". You'll not be able to use SAMBA."
>>
>
> More warnings removed - see above
>
>
Same same.
>> 581c547
>> < [ -z "$(strings $PATH_BIN/nxagent | egrep 'NXAGENT - Version
>> 1.5.0|NXAGENT - Version 2.[01].0|NXAGENT - Version 3.0.0')" ] && \
>> ---
>>
>> > [ -z "$(strings $PATH_BIN/nxagent | egrep 'NXAGENT - Version
>>
>> 1.5.0|NXAGENT - Version 2.[01].0|NXAGENT - Version 3.0.0|NXAGENT -
>> Version 3.1.0')" ] && \
>>
>
> This one looks justifiable. I would have gone for Version 3.[01].0 to keep
> things consistent, but that's just me ;-)
>
That is fine. But the main argument I have is to eliminate the dual
files for settings, and only put distro specific check logic in
nxloadconfig and variables should be moved or only set in node.conf.
Right now both files do both and it is needlessly confusing for
administrators.
That, and nxloadconfig and the binaries should go under /usr/sbin and
the libs should be under /usr/lib/nx and placed or put in ld.conf
standard search paths. /usr/libexec is stupid because it is yet another
library root for the sysadmin to remember to search for libraries.
I hope these arguments are clear.
-gc
> ________________________________________________________________
> Were you helped on this list with your FreeNX problem?
> Then please write up the solution in the FreeNX Wiki/FAQ:
> http://openfacts.berlios.de/index-en.phtml?title=FreeNX_FAQ
> Don't forget to check the NX Knowledge Base:
> http://www.nomachine.com/kb/
>
> ________________________________________________________________
> FreeNX-kNX mailing list --- FreeNX-kNX at kde.org
> https://mail.kde.org/mailman/listinfo/freenx-knx
> ________________________________________________________________
>
More information about the FreeNX-kNX
mailing list