HPE GreenLake Administration
- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- I have junk in my path , where did it come from??
Operating System - HP-UX
1836434
Members
2551
Online
110100
Solutions
Forums
Categories
Company
Local Language
back
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
back
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Blogs
Information
Community
Resources
Community Language
Language
Forums
Blogs
Go to solution
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-24-2004 08:20 AM
01-24-2004 08:20 AM
Notice the occurrence of // in the path.
> echo $PATH
.:/oracle/product/9.2.0.1.0/bin:/usr/bin:
/opt/ansic/bin:/usr/ccs/bin:/usr/contrib/bin:
/opt/mx/bin:/opt/hparray/bin:
/opt/nettladm/bin:/opt/upgrade/bin:
/opt/fcms/bin:/opt/pd/bin:/opt/resmon/bin:
/opt/ignite/bin:/usr/bin/X11:
/usr/contrib/bin/X11:/opt/graphics/common/bin:
/opt/scr/bin:/opt/netscape://opt/perl/bin:
/usr/sbin/diag/contrib:/opt/langtools/bin:
/opt/imake/bin:/opt/perf/bin:
/opt/sanmgr/commandview/client/sbin:
/opt/networker/bin:/opt/hpnpl//bin:
/usr/local/bin:/U01/local/SAS_8.2:/usr/lib:.
I cant tell who is sticking this in my PATH variable. I cant see /etc/profile nor /home/user/.profile doing it. Any thoughts?
> echo $PATH
.:/oracle/product/9.2.0.1.0/bin:/usr/bin:
/opt/ansic/bin:/usr/ccs/bin:/usr/contrib/bin:
/opt/mx/bin:/opt/hparray/bin:
/opt/nettladm/bin:/opt/upgrade/bin:
/opt/fcms/bin:/opt/pd/bin:/opt/resmon/bin:
/opt/ignite/bin:/usr/bin/X11:
/usr/contrib/bin/X11:/opt/graphics/common/bin:
/opt/scr/bin:/opt/netscape://opt/perl/bin:
/usr/sbin/diag/contrib:/opt/langtools/bin:
/opt/imake/bin:/opt/perf/bin:
/opt/sanmgr/commandview/client/sbin:
/opt/networker/bin:/opt/hpnpl//bin:
/usr/local/bin:/U01/local/SAS_8.2:/usr/lib:.
I cant tell who is sticking this in my PATH variable. I cant see /etc/profile nor /home/user/.profile doing it. Any thoughts?
Solved! Go to Solution.
3 REPLIES 3
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-24-2004 08:37 AM
01-24-2004 08:37 AM
Re: I have junk in my path , where did it come from??
Vernon,
While it may seem unlikely, I would triple check /etc/profile, /etc/PATH (which is most likely sourced in /etc/profile) and your ~/.profile file(s). It looks to me like someone fatfingered a forward slash is all.
Pete
Pete
While it may seem unlikely, I would triple check /etc/profile, /etc/PATH (which is most likely sourced in /etc/profile) and your ~/.profile file(s). It looks to me like someone fatfingered a forward slash is all.
Pete
Pete
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-24-2004 08:59 AM
01-24-2004 08:59 AM
Re: I have junk in my path , where did it come from??
Right. I found it in the /etc/PATH file. Thanks.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-25-2004 08:46 AM
01-25-2004 08:46 AM
Solution
/etc/PATH is the recommended way to keep a single location for setting the PATH variable. That way, different shells can all source a single location for the PATH setting. This is standard procedure to HP-UX and most HP-UX-aware applications put an entry in /etc/PATH during installation.
There is good new and bad news for this standard. The good news is that applications that expect executables to be found using $PATH will likely run without any adjustments (like creating symlinks or modifyinga bunch of .profiles, etc). The bad news is that $PATH gets extra long so searches can take a bit of time (although most of the PATH is usually cached) and it is hard to read when checking security. $PATH can be aecurity risk if it contains :: or :.: or if any of the directories are world-writable (Trojan horse attacks). It's also hard to see duplicates and non-existant locations.
Be careful about removing some of the PATH elements. Some applications may fail to run or run incorrectly. I personally think that all scripts and applications define their own PATH and never rely on whatever the sysadmin or user has created.
Bill Hassell, sysadmin
There is good new and bad news for this standard. The good news is that applications that expect executables to be found using $PATH will likely run without any adjustments (like creating symlinks or modifyinga bunch of .profiles, etc). The bad news is that $PATH gets extra long so searches can take a bit of time (although most of the PATH is usually cached) and it is hard to read when checking security. $PATH can be aecurity risk if it contains :: or :.: or if any of the directories are world-writable (Trojan horse attacks). It's also hard to see duplicates and non-existant locations.
Be careful about removing some of the PATH elements. Some applications may fail to run or run incorrectly. I personally think that all scripts and applications define their own PATH and never rely on whatever the sysadmin or user has created.
Bill Hassell, sysadmin
The opinions expressed above are the personal opinions of the authors, not of Hewlett Packard Enterprise. By using this site, you accept the Terms of Use and Rules of Participation.
Company
Events and news
Customer resources
© Copyright 2025 Hewlett Packard Enterprise Development LP