Operating System - HP-UX
1825764 Members
2098 Online
109687 Solutions
New Discussion

error on printing thru Oracle Apps

 
SOLVED
Go to solution
Ahmed M. AlShafiy
Regular Advisor

error on printing thru Oracle Apps

when we requst to printfrom oracle apps which installed on HP server i get this email from the server:


from lp@servername.com

error code 2 in request finance-1708 on printer finance

before we have a network printer called finance and we change the name only to be FIN and the IP address we don't change it.

can any one help me with this issue please.
31 REPLIES 31
Peter Godron
Honored Contributor

Re: error on printing thru Oracle Apps

Hi,
re-install your network printer on your server with the correct name.
Ahmed M. AlShafiy
Regular Advisor

Re: error on printing thru Oracle Apps

can i know how? please!!
Peter Godron
Honored Contributor

Re: error on printing thru Oracle Apps

Ahmed,
first you could try:
1. lpsched -v
2. chck your /var/adm/lp/log file
3. When you modified the name, did you also change the /var/spool/lp/request/ entry ?
4. Anything in syslog.log
5. If install via JetDiect, use hpnpoadmin -v


Bill Hassell
Honored Contributor

Re: error on printing thru Oracle Apps

I don't know of any simple way to change the name of a printer so whatever you did has likely messed up the printer's configuratin. Delete the printer and add it back again. If you're not familiar with the printer or how it was previously added, you'll need to talk to the system administrator as there are very different settings for 'network' printers depe3nding on the manufacturer of the printer and the printer's LAN card. If this is an HP printer with an HP JetDirect LAN card, you can use the hppi program. For non-HP printers, you'll need a lot of additional information about the printer.


Bill Hassell, sysadmin
Ahmed M. AlShafiy
Regular Advisor

Re: error on printing thru Oracle Apps

this what i have done:

nasjet:/#lpsched -v
lpsched: scheduler was already active
nasjet:/#cd var/spool/lp/request
nasjet:/var/spool/lp/request#ls
FIN PDRequest cit lqepson
nasjet:/var/spool/lp/request#hpnpoadmin -v
sh: hpnpoadmin: not found.
nasjet:/var/spool/lp/request#cd /
nasjet:/#hpnpoadmin -v
sh: hpnpoadmin: not found.


and when i access the printers thur SAM
i get the message that i attached.

please can you help me regarding...
Bill Hassell
Honored Contributor

Re: error on printing thru Oracle Apps

The hpnpadmin command was spelled incorrectly. However, there is no point in running the command until you can identify how the printer is connected. hpnpadmin only works with HP printers with an HP JetDirect LAN card.

The problem with SAM probably indicates that someone recently changed the name or hostname on the nasjet computer. You need to restart the swagent daemon:

/sbin/init.d/swagentd stop
/sbin/init.d/swagentd start

That should clear up the error from swlist. Then use SAM to identify the printer, delete it and add it back again.


Bill Hassell, sysadmin
Ahmed M. AlShafiy
Regular Advisor

Re: error on printing thru Oracle Apps

i restart the sw as you:

but i have the same error and when i access the hosts file from sam i find a symbol after the host name can you see it i attached
Victor BERRIDGE
Honored Contributor

Re: error on printing thru Oracle Apps

Hi Ahmed,

Try to edit your /etc/hosts file with vi:
vi /etc/hosts
Then look for any special characters especially after you different hosts (printer) names.
See if once at beginning of a name in edit mode of vi press e (end of word), are you at the expected last character?
Once that is clarified, try to ping your printers, do they respond?


All the best
Victor
Bill Hassell
Honored Contributor

Re: error on printing thru Oracle Apps

Your hostname has been corrupted along with your printer names. You need to edit /etc/hosts and fix the bad characters. Also check your netconf file for similar problems.


Bill Hassell, sysadmin
Ahmed M. AlShafiy
Regular Advisor

Re: error on printing thru Oracle Apps

i have edit the hosts file to be like this:

nasjet:/etc#more hosts
# @(#)B.11.11_LRhosts $Revision: 1.9.214.1 $ $Date: 96/10/08 13:20:01 $
#
# The form for each entry is:
#
#
# For example:
# 192.1.2.34 hpfcrm loghost
#
# See the hosts(4) manual page for more information.
# Note: The entries cannot be preceded by a space.
# The format described in this file is the correct format.
# The original Berkeley manual page contains an error in
# the format description.
#
10.3.242.24 nasjet
10.3.242.24 nasjet nasjet.nasaviation.com

127.0.0.1 localhost loopback
10.3.243.100 FIN
10.3.243.100 lqepson


but when i access it from SAM i find it as i attached image, please what can i do??
Bill Hassell
Honored Contributor

Re: error on printing thru Oracle Apps

You have two duplicates in the hosts file. An IP address must appear once in this file. Aliases can appear on the same line. Change from:

> 10.3.242.24 nasjet
> 10.3.242.24 nasjet nasjet.nasaviation.com
> 10.3.243.100 FIN
> 10.3.243.100 lqepson

to:

10.3.242.24 nasjet nasjet.nasaviation.com
10.3.243.100 lqepson FIN

I'm not sure why you have an all UPPERCASE name for lqepson. Now this change may fix SAM but the order of hostname resolution depends on two other files in /etc: resolv.conf and nsswitch.conf. Note that you do NOT need a hostname to add a printer. In SAM, just use the IP address for the print server's hostname.


Bill Hassell, sysadmin
Ahmed M. AlShafiy
Regular Advisor

Re: error on printing thru Oracle Apps

if i want to test the printer from root command line what is the command for that?
Bill Hassell
Honored Contributor
Solution

Re: error on printing thru Oracle Apps

The lp command is a poor test but you can try it:

lp -dfinabce /etec/profile

But the original question is still: how is this printer connected? Is it on another server? Is it connected with a cable directly to the HP-UX system? Is it connected on the LAN with an HP network card or is it connected with a non-HP network card?


Bill Hassell, sysadmin
Ahmed M. AlShafiy
Regular Advisor

Re: error on printing thru Oracle Apps

the printer is conected to the network thru it's own network card and it's HP printer and it has it own IP address.

and it was printing fine and we have change the name of the printer.

how can we reconfig it again??
Bill Hassell
Honored Contributor

Re: error on printing thru Oracle Apps

OK. Run SAM and delete the existing printer. Then exit SAM and run this command to verify communication:

/opt/hpnpl/bin/hpnpadmin -v 12.34.56.78

where 12.34.56.78 is the IP address of the printer. The first few lines will show that it is an HP network printer. If not, post the results.

Once this test is complete, just add the printer with this command:

/opt/hpnpl/bin/addqueue -h 12.34.56.78 -q finance

And that's all there is to it. You can test it with hpnpf (to bypass the spooler):

/opt/hpnpl/bin/hpnpf -x 12.34.56.78 -N /etc/profile

Then test it with the lp command mentioned above.


Bill Hassell, sysadmin
Ahmed M. AlShafiy
Regular Advisor

Re: error on printing thru Oracle Apps

i don't find hpnpl as shows below:


/opt/hpnpl/bin/hpnpadmin -v 10.3.240.100
+ /opt/hpnpl/bin/hpnpadmin -v 10.3.240.100
sh: /opt/hpnpl/bin/hpnpadmin: not found.
# cd opt
+ cd opt
# cd hpnpl
+ cd hpnpl
sh: hpnpl: not found.
# ls
+ ls
Migration aCC hparray java1.4 nettladm snia
Netscape asx hpwebadmin langtools networkdocs softbench
OV audio hpws lost+found openssl upgrade
VRTS cifsclient icod mozilla parmgr video
VRTSfspro dce ifor mpt pd wbem
VRTSob dcelocal ignite mx raid4si webadmin
VRTSvlic fcms image mysql resmon
VRTSvmpro gnome java1.2 netscape samba
VRTSvxms graphics java1.3 netscape6 samba_src
#


how we can solve it?
Bill Hassell
Honored Contributor

Re: error on printing thru Oracle Apps

You do not have the HPPI software installed. Now I can go through the steps to get HPPI installed but since you already had a working printer, I'm not sure how you added the printer in the first place. Use this command:

ll -d /opt/hpnp*

If there is an hpnp directory, then you have the obsolete jetadmin software. If you do not have anything shown, then your must have been added incorrectly as a remote printer.

Here is the location for the HPPI software:

http://h20000.www2.hp.com/bizsupport/TechSupport/SoftwareIndex.jsp?lang=en&cc=us&prodNameId=18922&prodTypeId=18972&prodSeriesId=27349&swLang=8&taskId=135&swEnvOID=7



Bill Hassell, sysadmin
Ahmed M. AlShafiy
Regular Advisor

Re: error on printing thru Oracle Apps

we have to server now i can print from the test one i have configure the printer thru SAM by adding a network printer and it's working fine thanks all of you.

but now i'm facing a problem with the next server when i try to add a printer i get the attaced message ever after i have stop the swagentd and restart it.


can you help me to solve it ASAP please.
Bill Hassell
Honored Contributor

Re: error on printing thru Oracle Apps

Make sure all SD programs are terminated. Use:

ps -ef | grep sw

Programs like swlist, swinstall, swagentd, swverify, etc. Note that the correct way to stop and start swagentd is with the start/stop script:

/sbin/init.d/swagentd stop
/sbin/init.d/swagentd start

Now try running SAM.

The reason you were able to add the printer without downloading HPPI is that you are running on an old version of JetDirect software. The directory with the tools is localted in /opt/hpnp/bin. This software is not only obsolete, it has known Y2K problems and should be replaced. I am assuming that your version of HP-UX is 10.01 or higher.


Bill Hassell, sysadmin
Ahmed M. AlShafiy
Regular Advisor

Re: error on printing thru Oracle Apps

here what have i done and still have the same problem:

nasjet:/#ps -ef | grep sw
root 0 0 0 Sep 3 ? 10:27 swapper
root 27148 1 2 Sep 22 ? 0:02 /usr/sbin/swagentd -r
nasjet:/#kill -9 27148
nasjet:/#ps -ef | grep sw
root 0 0 0 Sep 3 ? 10:27 swapper
nasjet:/#/sbin/init.d/swagentd stop
The swagentd daemon is stopped.
nasjet:/#/sbin/init.d/swagentd start
nasjet:/#sam
Ahmed M. AlShafiy
Regular Advisor

Re: error on printing thru Oracle Apps

please need your help UERGENT!!!
Bill Hassell
Honored Contributor

Re: error on printing thru Oracle Apps

Start by looking at /var/adm/sw/swagentd.log as mentioned in the error message. Also, run swverify to see what errors exist in the LP spooler software:

swverify PrinterMgmt

At the end of the listing, it will have a message like this:

More information may be found in the agent logfile using the command "swjob -a log nasjet-0102 @ nasjet:/

Run the swjob command to see the errors. Fix the errors, then try SAM again.


Bill Hassell, sysadmin
Ahmed M. AlShafiy
Regular Advisor

Re: error on printing thru Oracle Apps

i have check the swagentd.log and i have follow up the steps that you are said above and this the result:

nasjet:/#swjob -a log nasjet-0102@nasjet:/
WARNING: An attempt to get the network host entry for "nasjet" failed.
This may result in denial of access to users and agents at
this host. Check the spelling of this name, then your
"/etc/hosts" file, or your "/etc/resolv.conf" file and DNS
resolver configuration. The nslookup program may be helpful
in isolating this problem.
ERROR: Cannot set the security context for this session. Cannot
determine the user's identification. Please give this
information to your Hewlett-Packard support person.

how i can fixed the error above??
Ahmed M. AlShafiy
Regular Advisor

Re: error on printing thru Oracle Apps

and when i try nslookup i get this:


nasjet:/#nslookup
*** Warning - the local domain is not set.
*** Either hostname should be a domain name,
*** the domain should be specified in /etc/resolv.conf,
*** or the shell variable LOCALDOMAIN should be set.

Default Name Server: jeddahdc.nasaviation.com
Address: 10.3.242.52