Sponsored Content
Top Forums UNIX for Beginners Questions & Answers ARP and Bonjour to build list of user devices Post 302993622 by drysdalk on Sunday 12th of March 2017 10:22:11 AM
Old 03-12-2017
Hi,

In general, if a command works at the shell prompt, it should work if that same command is put in a script that is run by that same shell. What might be happening here perhaps is that paths when running via crontab might not be what you'd expect.

If you try in your script putting full absolute paths to all binaries and files, does it then work OK via a crontab entry ? That's probably the first thing to try, since if this approach is working for you at the command line, it should (generally speaking) work in a script as well.

Also make sure the shebang line at the top of your script matches the shell you expect to use to run the script (so #!/bin/bash for Bash, for instance), in case there is a difference between your own shell and the system default shell, or the shell the user is running as in cron.
This User Gave Thanks to drysdalk For This Post:
 

6 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

passthrough devices vs. named devices

I am having trouble understanding the difference between a passthrough device and a named device and when you would use one or the other to access equipment. As an example, we have a tape library and giving the command "camcontrol devlist" gives the following output: akx# camcontrol... (1 Reply)
Discussion started by: thumper
1 Replies

2. HP-UX

list of devices

Hi, I need to rediracte all the names of the devices (only disks) to a file. Thanks:confused: (3 Replies)
Discussion started by: yoavbe
3 Replies

3. Shell Programming and Scripting

Run SQL command for a list of devices

Hi Please help me to resolve. Question: I can run this command to change the mode of a device with id=500 as below dbc "select device mode=3 where id=500;" How can i run the same query with a file contaning n number of ids ? file1.txt 12 234 34 500 34 45 Thanks in... (3 Replies)
Discussion started by: sureshcisco
3 Replies

4. Shell Programming and Scripting

Perl - run sub routine for list of devices

Hi, Can anyone please correct the script such that it run on all the devices in the devicelist.txt file. The problem is when the script runs it only reads the first device in the list, configures the device and exists. Script: The devicelist.txt: device.crs... (1 Reply)
Discussion started by: sureshcisco
1 Replies

5. UNIX for Dummies Questions & Answers

Adding SDK Build on Kernel Source Build

Hi, So I downloaded this kernel source and was able to build it successfully. But I want to add this SDK source code inside, can anyone help me how to do this? Note that the SDK source can be built by itself. I added the SDK in the main Makefile: init-y := init/ #added SDK... (0 Replies)
Discussion started by: h0ujun
0 Replies

6. UNIX for Advanced & Expert Users

How to handle build user access/permissions?

All, I am looking for some guidance on how to handle permissions/access for an application build/deployment. We need to allow for software deployments via Visual Studio Team Services and a build server running on Windows, deploying to RHEL 7 servers. We would like to use a service account,... (3 Replies)
Discussion started by: hburnswell
3 Replies
platform::shell(n)					       Tcl Bundled Packages						platform::shell(n)

__________________________________________________________________________________________________________________________________________________

NAME
platform::shell - System identification support code and utilities SYNOPSIS
package require platform::shell ?1.1.4? platform::shell::generic shell platform::shell::identify shell platform::shell::platform shell _________________________________________________________________ DESCRIPTION
The platform::shell package provides several utility commands useful for the identification of the architecture of a specific Tcl shell. This package allows the identification of the architecture of a specific Tcl shell different from the shell running the package. The only requirement is that the other shell (identified by its path), is actually executable on the current machine. While for most platform this means that the architecture of the interrogated shell is identical to the architecture of the running shell this is not generally true. A counter example are all platforms which have 32 and 64 bit variants and where a 64bit system is able to run 32bit code. For these running and interrogated shell may have different 32/64 bit settings and thus different identifiers. For applications like a code repository it is important to identify the architecture of the shell which will actually run the installed packages, versus the architecture of the shell running the repository software. COMMANDS
platform::shell::identify shell This command does the same identification as platform::identify, for the specified Tcl shell, in contrast to the running shell. platform::shell::generic shell This command does the same identification as platform::generic, for the specified Tcl shell, in contrast to the running shell. platform::shell::platform shell This command returns the contents of tcl_platform(platform) for the specified Tcl shell. KEYWORDS
operating system, cpu architecture, platform, architecture platform::shell 1.1.4 platform::shell(n)
All times are GMT -4. The time now is 02:36 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy