Sponsored Content
Top Forums Shell Programming and Scripting Move files from one location to another Post 302409629 by TonyFullerMalv on Thursday 1st of April 2010 05:21:46 PM
Old 04-01-2010
Not quite what you are asking but nearly.
If the 28th Feb. was 33 days ago then:
Code:
find /data/NewJersey -type f -mtime +33 -exec mv {} /home/scripts/NJ ;/

You could give this a try?

The version of Unix determines what options you have available to the find(1) command, so what version of Unix are you using?
 

10 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

How to move an application from one location to another

Hi all, I have installed an application (RRDTool) in /usr/local directory, Can any one tell me how I can move this to some other location along with the libraries. Thanks in Advance. (3 Replies)
Discussion started by: KK Varma
3 Replies

2. UNIX for Advanced & Expert Users

copy files from one location to similar location

I need help in forming a script to copy files from one location which has a sub directory structure to another location with similar sub directory structure, say location 1, /home/rick/tmp_files/1-12/00-25/ here 1-12 are the number of sub directories under tmp_files and 00-25 are sub... (1 Reply)
Discussion started by: pharos467
1 Replies

3. Shell Programming and Scripting

Transfer files from one location to another location

Hi, i have to transfer of files of User1 located in Location1 to user2 located in Location2 using shell script. Please suggest me. (1 Reply)
Discussion started by: KiranKumarKarre
1 Replies

4. Shell Programming and Scripting

Shell Script for Copy files from one location to another location

Create a script that copies files from one specified directory to another specified directory, in the order they were created in the original directory between specified times. Copy the files at a specified interval. (2 Replies)
Discussion started by: allways4u21
2 Replies

5. UNIX for Dummies Questions & Answers

Schedule a move job, from one location to another

There are two similar directory structures existing, e.g. old/ and new/, where old/d1/d2/d4/, old/d1/d2/d5/, old/d1/d3/d6/ and old/d1/d3/d7 contains some files and now I want to move those files from each folder to new locations new/d1/d2/d4/, new/d1/d2/d5/, new/d1/d3/d6/ and new/d1/d3/d6/. The... (1 Reply)
Discussion started by: abkush
1 Replies

6. Shell Programming and Scripting

After FTP unable to move file to other location

Hi Experts, I am using below script and facing some problems.. cd /home/user/test rm ftp://ftp.log Example: A_Bachfile_09292011.txt A=`ls -1 "A*.txt"` compress $A C=`ls -1 "A*` hostname="test.gmail.com" user="raju" Password="******" ftp -n $hostname <<EOF >>ftp.lpg... (4 Replies)
Discussion started by: rajubollas
4 Replies

7. Shell Programming and Scripting

move files to a different location

Hi Guys, I need to write a script that will loop on all of my oracle databases on a server and move archivelogs from archive destination to a different location. I do have a function to loop on all databases on a server. I want help in writing a fuction to dynamically get the archive... (1 Reply)
Discussion started by: Phuti
1 Replies

8. Shell Programming and Scripting

How to find a word and move it a specific location in xml file using perl?

Hi friends, I have one XML file having below structure :- INput XML file :- <?xml version="1.0" encoding="UTF-8"?> <START> <A=value1> <attr name1="a1"> </A> <B=value2> <attr name2="b1"> <attr name3="c1"> </B> </START> output xml file should be === (3 Replies)
Discussion started by: harpal singh
3 Replies

9. Shell Programming and Scripting

How to move a file in ftp command to other location?

hi, when i do ftp from unix to laptop which is running a windows os, it lands in a root folder. can i move a file from this root ftp folder to any other location in my laptop say , c:\files\ folder? i used rename command inside ftp , but it says incorrect parameter. (5 Replies)
Discussion started by: Little
5 Replies

10. Shell Programming and Scripting

Help with copying the list of files from one location to other location

A) I would like to achive following actions using shell script. can someone help me with writing the shell script 1) Go to some dir ( say /xyz/logs ) and then perform find operation in this dir and list of subdir using find . -name "*" -print | xargs grep -li 1367A49001CP0162 >... (1 Reply)
Discussion started by: GG2
1 Replies
PACEMAKER(8)						  System Administration Utilities					      PACEMAKER(8)

NAME
Pacemaker - Part of the Pacemaker cluster resource manager SYNOPSIS
crm_resource (query|command) [options] DESCRIPTION
crm_resource - Perform tasks related to cluster resources. Allows resources to be queried (definition and location), modified, and moved around the cluster. OPTIONS
-?, --help This text -$, --version Version information -V, --verbose Increase debug output -Q, --quiet Print only the value on stdout -r, --resource=value Resource ID Queries: -L, --list List all resources -l, --list-raw List the IDs of all instantiated resources (no groups/clones/...) -O, --list-operations List active resource operations. Optionally filtered by resource (-r) and/or node (-N) -o, --list-all-operations List all resource operations. Optionally filtered by resource (-r) and/or node (-N) -q, --query-xml Query the definition of a resource (template expanded) -w, --query-xml-raw Query the definition of a resource (raw xml) -W, --locate Display the current location(s) of a resource -A, --stack Display the prerequisites and dependents of a resource -a, --constraints Display the (co)location constraints that apply to a resource Commands: -p, --set-parameter=value Set the named parameter for a resource. See also -m, --meta -g, --get-parameter=value Display the named parameter for a resource. See also -m, --meta -d, --delete-parameter=value Delete the named parameter for a resource. See also -m, --meta -M, --move Move a resource from its current location, optionally specifying a destination (-N) and/or a period for which it should take effect (-u) If -N is not specified, the cluster will force the resource to move by creating a rule for the current location and a score of -INFINITY NOTE: This will prevent the resource from running on this node until the constraint is removed with -U -U, --un-move Remove all constraints created by a move command Advanced Commands: -D, --delete Delete a resource from the CIB -F, --fail Tell the cluster this resource has failed -R, --refresh (Advanced) Refresh the CIB from the LRM -C, --cleanup (Advanced) Delete a resource from the LRM -P, --reprobe (Advanced) Re-check for resources started outside of the CRM Additional Options: -N, --node=value Host uname -t, --resource-type=value Resource type (primitive, clone, group, ...) -v, --parameter-value=value Value to use with -p, -g or -d -u, --lifetime=value Lifespan of migration constraints -m, --meta Modify a resource's configuration option rather than one which is passed to the resource agent script. For use with -p, -g, -d -z, --utilization Modify a resource's utilization attribute. For use with -p, -g, -d -s, --set-name=value (Advanced) ID of the instance_attributes object to change -i, --nvpair=value (Advanced) ID of the nvpair object to change/delete -f, --force EXAMPLES
List the configured resources: # crm_resource --list Display the current location of 'myResource': # crm_resource --resource myResource --locate Move 'myResource' to another machine: # crm_resource --resource myResource --move Move 'myResource' to a specific machine: # crm_resource --resource myResource --move --node altNode Allow (but not force) 'myResource' to move back to its original location: # crm_resource --resource myResource --un-move Tell the cluster that 'myResource' failed: # crm_resource --resource myResource --fail Stop a 'myResource' (and anything that depends on it): # crm_resource --resource myResource --set-parameter target-role --meta --parameter-value Stopped Tell the cluster not to manage 'myResource': The cluster will not attempt to start or stop the resource under any circumstances. Useful when performing maintenance tasks on a resource. # crm_resource --resource myResource --set-parameter is-managed --meta --parameter-value false Erase the operation history of 'myResource' on 'aNode': The cluster will 'forget' the existing resource state (including any errors) and attempt to recover the resource. Useful when a resource had failed permanently and has been repaired by an administrator. # crm_resource --resource myResource --cleanup --node aNode AUTHOR
Written by Andrew Beekhof REPORTING BUGS
Report bugs to pacemaker@oss.clusterlabs.org Pacemaker 1.1.7 April 2012 PACEMAKER(8)
All times are GMT -4. The time now is 02:11 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy