Linux Users

cancel
Showing results for 
Search instead for 
Did you mean: 

NIKAL/VISA driver install on gentoo system

Hello everybody,

I am hoping someone here may have a suggestion for a strange problem I am encountering.

I installed Labview-Pro-Dev on a gentoo system (kernel 2.6.25-r9).  The installer created the Labview-8.6, lvmerge, nisvcloc, pipeline, and share directory structure and associated files under /usr/local/natinst.  Notice that I selected "no" to installing the drivers. Next I installed NIKAL-1.9 from its own iso image by running ./INSTALL as root.  The installer exitted without error asking for reboot.  I answered "no" and proceded to installing NI-VISA-4.5 and NI-DAQmx in a similar fashion, using the iso images and the INSTALL scripts included with each.  No errors reported on any of the driver installs.

I noticed that no additional directories were created under /usr/local/natinst by the subsequent driver installations using the ISOs.  I rebooted anyway and, no surprise, the system has no trace of ni modules or tools like updateNIdrivers.

My system has rpm2targz package installed but no other rpm tools.  Strangely, previously, installing on a different system, again without additional rpm tools installed, has produced a valid installation.

I am confused by the success exit with absolutely no errors generated by the driver installation sequence while no actual install appears to be performed.

Any suggestions will be appreciated.

Thanks

rar2

0 Kudos
Message 1 of 9
(5,901 Views)

I just skimmed over the NI-KAL INSTALL script and it looks like you are right... If we don't find rpm we don't error out and we don't install anything.  This looks like a bug in our INSTALL script that slipped through since we don't test on non rpm based distros.

My suggestion is to install rpm on your gentoo machine.  You may need to install with "./INSTALL --nodeps" since your rpm database won't be poplated with dependency info.  Either that or you can try using rpm2targz to unpack the rpms but I wouldn't recommend it since the INSTALL script and rpm pre/post scripts perform some extra steps besides just copying files to the system.

Shawn Bohrer

National Instruments

Use NI products on Linux? Come join the NI Linux Users Community
0 Kudos
Message 2 of 9
(4,453 Views)

Shawn,

Thank you for your quick reply.  Kudos to you for doing a great job and to NI for supporting linux.

I ran the INSTALL scripts for the NIKAL, NI-VISA, and GPIB using  the --nodeps option.

NIKAL installed ran without error.

VISA reported:

Installing NI-VISA for Linux version 4.5.0f0...
Pre Installation .
Post Installation .
Skipping nikali-1.9.0-f0.noarch.rpm installation, same or newer already installed.
Pre Installation ..................
Preparing...                ########################################### [100%]
   1:nivisaserver           ########################################### [  7%]
   2:nipalki                ########################################### [ 13%]
   3:nipali                 ########################################### [ 20%]
rc0.d directory not found, startup script not being registered with init levels.
   4:labview82-rte          ########################################### [ 27%]
   5:nicvirte               ########################################### [ 33%]
   6:nidimi                 ########################################### [ 40%]
   7:nimdnsresponder        ########################################### [ 47%]
rc0.d directory not found, startup script not being registered with init levels.
   8:niorbi                 ########################################### [ 53%]
   9:nipxirmi               ########################################### [ 60%]
  10:nirpci                 ########################################### [ 67%]
  11:nispyi                 ########################################### [ 73%]
  12:nivisa                 ########################################### [ 80%]
rc0.d directory not found, startup script not being registered with init levels.
  13:nivisa-config          ########################################### [ 87%]
  14:nivisa-devel           ########################################### [ 93%]
  15:nivisak                ########################################### [100%]
Post Installation ..................

FOR PATENTS COVERING NATIONAL INSTRUMENTS PRODUCTS, REFER TO
THE PATENTS.txt FILE ON /mnt/cdrom AND/OR
www.ni.com/patents

******************************************************************************
* A reboot is required before attempting to use the
* NI-VISA for Linux software.
******************************************************************************


Would you like to reboot now? [yes|no] no

NI-VISA for Linux Installation completed successfully.

Please reboot manually before attempting to use
NI-VISA for Linux software.

At this point I checked time stamps (ls -laht) for the scripts installed/linked in init.d during install and found: nipxirmu nilxid nimdnsd nipal nisvcloc. I added them to runlevel default

Finally tried installing GPIB with nodeps from the ProDev DVD after installing rpm utilities:

Installing NI-488.2 Distribution version 2.5.1f0...
Skipping nikali-1.4.0-f0.i386.rpm installation, same or newer already installed.
Skipping nipali-1.11.0-f0.i386.rpm installation, same or newer already installed.
Skipping nispyi-2.4.0-f0.i386.rpm installation, same or newer already installed.
Pre Installation ......
Preparing...                ########################################### [100%]
   1:ni4882i                ########################################### [ 50%]
* nipalwrapper added to runlevel default
* gpibenumsvcwrapper added to runlevel default
   2:labview80-rte          ########################################### [100%]
Post Installation ......
* Caching service dependencies ...
*  Can't find service 'cluster-manager' needed by 'clvmd';  continuing...
*  Can't find service 'cluster-locking-manager' needed by 'clvmd';  continuing...
*  Can't find service 'fenced' needed by 'clvmd';  continuing...                                                                                             [ ok ]

FOR PATENTS COVERING NATIONAL INSTRUMENTS PRODUCTS, REFER TO
THE PATENTS.txt FILE ON /mnt/cdrom/NI-488 AND/OR
www.ni.com/patents

******************************************************************************
* A reboot is required before attempting to use the
* NI-488.2 Distribution software.
******************************************************************************

NI-488.2 Distribution Installation completed successfully.

Please reboot manually before attempting to use
NI-488.2 Distribution software.

I checked again for latest changes in init.d and found that gpibenumsvc, gpibenumsvcwrapper, and nipalwrapper had been added by the install script but only the wrapper scripts had been added to the default runlevel.  I checked the wrapper scripts and indeed they are written in "gentoo style".


Now to the questions regarding adding the init scripts to the default runlevel.  Essentially, I'd like to know what scripts should be added and in what general order.

Specifically:

Q1:  What scripts should be added to default and in what order by the NI-VISA install?

Q2: Similar question for the GPIB install. I am assuming that only the wrapper scripts and no gpibenumsvc and nipal should be added to default runlevel?  Is this correct?

Q3: In what order should the init scripts be run?  If there are general "before", "after",  "depend" type requirements  I can add them directly to the scripts on my system.

Thank you again for your support.

rar2

PS:

I tried to install DAQmx (INSTALL --nodeps run from the iso) and got the following error:

Post Installation ...............................
error: Failed dependencies:
        labview86-core is needed by lvsupport86-daqmxexmp-1.4.3-f0.i386
        /bin/sh is needed by lvsupport86-daqmxexmp-1.4.3-f0.i386
        labview86-core is needed by lvsupport86-daqmxsupp-1.4.3-f0.i386
        /bin/sh is needed by lvsupport86-daqmxsupp-1.4.3-f0.i386
        labview86-core is needed by lvsupport86-daqmxviref-1.0.1-f0.i386
        /bin/sh is needed by lvsupport86-daqmxviref-1.0.1-f0.i386
Error installing NI-DAQmx for Linux Installer Distribution 8.0.1f0.

Installer is aborted.

I know that labview86-core is installed (I re-run the installation of the ProDEV DVD anyway just to be sure) and obviously bash is there.  So it seems that the post install does not obey the "--nodeps" directive.

To "freshen" the rpm database, should I run:

rpm -Fvh --justdb labview86-core-8.6.0-1.i386.rpm

On the other hand I don't see how this will take care of the required /bin/sh dep.  Any other suggestions?  Maybe modifying the postinstall part of the script?

Thanks again.

Message was edited by: rar2

0 Kudos
Message 3 of 9
(4,453 Views)

I'm not sure I have answers to all of your questions, and don't have time at the moment to look into them, but I'll answer what I can.

rar2 wrote:

VISA reported:

Installing NI-VISA for Linux version 4.5.0f0...

...

NI-VISA for Linux Installation completed successfully.

Please reboot manually before attempting to use
NI-VISA for Linux software.

At this point I checked time stamps (ls -laht) for the scripts installed/linked in init.d during install and found: nipxirmu nilxid nimdnsd nipal nisvcloc. I added them to runlevel default

Does Gentoo support standard sysV init scripts?  I'm guessing it does, but if I remember correctly it has different runlevels.

NI-488.2 Distribution Installation completed successfully.

Please reboot manually before attempting to use
NI-488.2 Distribution software.

I checked again for latest changes in init.d and found that gpibenumsvc, gpibenumsvcwrapper, and nipalwrapper had been added by the install script but only the wrapper scripts had been added to the default runlevel.  I checked the wrapper scripts and indeed they are written in "gentoo style".

I had never seen these gpibenumsvcwrapper, and nipalwrapper scripts before so I took a look at the NI-488.2 installer.  Interestingly it checks if you are running Gentoo, and creates Gentoo style init scripts that wrap the gpibenumsvc, and nipal init scripts.  If gentoo actually supports sysV init scripts I'm not sure why this is needed, but it does install the scripts with rc-update which is nice.  Just for the record NI-488.2 doesn't officially support Gentoo, but I believe some work was done to support a custom opportunity which is why this exists.

Q1:  What scripts should be added to default and in what order by the NI-VISA install?

Q2: Similar question for the GPIB install. I am assuming that only the wrapper scripts and no gpibenumsvc and nipal should be added to default runlevel?  Is this correct?

Really you should add all of the init scripts to your default runlevel.  After looking at the gpibenumsvcwrapper and nipalwrapper scripts if you have these in your default runlevel you do not need to add the gpibenumsvc and nipal init scripts.

Q3: In what order should the init scripts be run?  If there are general "before", "after",  "depend" type requirements  I can add them directly to the scripts on my system.

I'm just going to guess here, but you should be able to determine the order by looking at the headers in each script.

nipal(or wrapper): first

gpibenumsvc(or wrapper): depends on nipal, may depend on network

nipxirmu: probably depends on nipal

nimdnsd: probably depends on network

nilxid: probably depends on nimdnsd

nisvcloc:  I have no idea what this depends on.  I think it may depend on network, and possibly nipal

PS:

I tried to install DAQmx (INSTALL --nodeps run from the iso) and got the following error:

Post Installation ...............................
error: Failed dependencies:
        labview86-core is needed by lvsupport86-daqmxexmp-1.4.3-f0.i386
        /bin/sh is needed by lvsupport86-daqmxexmp-1.4.3-f0.i386
        labview86-core is needed by lvsupport86-daqmxsupp-1.4.3-f0.i386
        /bin/sh is needed by lvsupport86-daqmxsupp-1.4.3-f0.i386
        labview86-core is needed by lvsupport86-daqmxviref-1.0.1-f0.i386
        /bin/sh is needed by lvsupport86-daqmxviref-1.0.1-f0.i386
Error installing NI-DAQmx for Linux Installer Distribution 8.0.1f0.

Installer is aborted.

I know that labview86-core is installed (I re-run the installation of the ProDEV DVD anyway just to be sure) and obviously bash is there.  So it seems that the post install does not obey the "--nodeps" directive.

To "freshen" the rpm database, should I run:

rpm -Fvh --justdb labview86-core-8.6.0-1.i386.rpm

On the other hand I don't see how this will take care of the required /bin/sh dep.  Any other suggestions?  Maybe modifying the postinstall part of the script?

Interesting, it looks like --nodeps doesn't get applied to lvsupport packages.  I'll file another bug report.  What I don't understand is why it is complaining about labview86-core missing did you install LabVIEW 8.6 before you had rpm installed?  What does "rpm -qa | grep -i labview" show?  Anyway to fix the problem you may need to unpack the tarball on the NI-DAQmx iso and run:

rpm -Uvh --nodeps lvsupport86-daqmxexmp-1.4.3-f0.i386.rpm lvsupport86-daqmxsupp-1.4.3-f0.i386.rpm lvsupport86-daqmxviref-1.0.1-f0.i386.rpm

Shawn Bohrer

National Instruments

Use NI products on Linux? Come join the NI Linux Users Community
0 Kudos
Message 4 of 9
(4,453 Views)

Hi Shawn,

Thank you for your suggestions regarding the init scripts.  To answer your question, gentoo has a "custom" version of the sysv init, with different runlevels.  The start order is decided based on the "before", "after", "depend", "provide" directives in all scripts present in a runlevel.  I'll look at the header files and use your suggestions to make wrapper scripts.

Running the command you suggested:

~ $ rpm -qa | grep -i labview
labview80-rte-8.0.1-1.i386
labview82-rte-8.2.1-2.i386

Regarding the bug related to installing lvsupport packages by the NIDAQmx installer, I think the rpm database is not updated by the labview8.6 installer because it actually checks for gentoo and sets RPM=no.

The reason I suggested to "freshen" the rpm database (run: rpm -Fvh --justdb labview86-core-8.6.0-1.i386.rpm) instead of manually installing the lvsupport86 packages as you suggested was to allow the DAQmx installer to run by itself and perform any additional actions needed.   I looked at the script and it appears that it adds some soft links among other things (I find the script a bit overwhelming to be honest).  Notice that I am assuming that this will solve the /bin/sh dependency problem but my hopes are not very high.

Now, I do not foresee a problem with testing this approach (freshen the rpm database by adding the labview86-core package without touching the file system), but it's been a while since I encountered the "rpm dependency hell" (reason I moved away from RHEL a couple of years back).  So I am a bit aprehensive about messing up things even more.

Considering the above and your much more detailed knowledge of the install script, which approach do you recommend?

Thanks so much.  Your help is highly appreciated.

rar2

0 Kudos
Message 5 of 9
(4,453 Views)

I think the "rpm -Fvh --justdb labview86-core-8.6.0-1.i386.rpm" trick may work to fix the labview86-core dependency, but I don't think it will fix the /bin/sh dependency.  If it were me I would just apply the attached patch to the NI-DAQmx 8.0.1 INSTALL script with:

patch INSTALL 0001-Install-lvsupport-packages-with-nodeps.patch

That will force it to install the labview86 support packages with --nodeps.  If you need support for other LabVIEW versions you would need to make a few more edits.

Shawn Bohrer

National Instruments

Use NI products on Linux? Come join the NI Linux Users Community
0 Kudos
Message 6 of 9
(4,453 Views)

Shawn, thanks for uploading the patch.  Is there a special procedure to follow to get it?  Curently it shows "queued" but provides no link.

Thank again very much.

rar2

0 Kudos
Message 7 of 9
(4,453 Views)

rar2 wrote:

Shawn, thanks for uploading the patch.  Is there a special procedure to follow to get it?  Curently it shows "queued" but provides no link.

Thank again very much.

rar2

I think that "queued" message is special feature of these forums that makes users wait in eager anticipation only to find out it was a simple one line patch   It looks like you can download the patch now, I have no idea why it takes so long though.

Shawn

Use NI products on Linux? Come join the NI Linux Users Community
0 Kudos
Message 8 of 9
(4,453 Views)

Great! Thanks, it worked!

Now back to writing the wrapper scripts

Have a great day!

rar2

0 Kudos
Message 9 of 9
(4,453 Views)