Sponsored Content
Top Forums UNIX for Dummies Questions & Answers How to copy/move to a file with a special character as the 1st char in the filename? Post 302266463 by methyl on Wednesday 10th of December 2008 08:58:16 AM
Old 12-10-2008
Assuming this is on a non-operational system.

cp -p foo.bar ./-rubbish

To remove file.
rm -i ./-rubbish

You would be advised to not leave files like this on a live server. They upset basic unix commands and backup software.
 

10 More Discussions You Might Find Interesting

1. HP-UX

special character on Filename.. help!!!urgent

I'm trying to rename a file name but the original file has a special character caused by typo. I've tried numerous combination of characters but the file name (original) is still not being recognized which in turn, would not allow me to rename the file. Can someone help? The filename is a... (1 Reply)
Discussion started by: genzbeat
1 Replies

2. Shell Programming and Scripting

move filenames with to another filename without the last character ~

Hi, I need to move filenames with the following format below into filenames without the ~ like sample below. I hope you can help me create a simple unix script that will do this. Thanks in advance! move filename from: AIRS20081225-235641.BSP~ AIRS20081225-235648.BSP~ AIRS20081225-235640.BSP~... (3 Replies)
Discussion started by: ayhanne
3 Replies

3. Shell Programming and Scripting

File Move Based on 1st Character of File Name

I need some help with a unix script to mv image files to subdirectories based on the 1st character of the filename. See example below... /images/main 1191.jpg 9999.jpg A101.jpg A102.jpg B201.jpg c333.jpg ... Z999.jpg I would like to move to the following: ... (11 Replies)
Discussion started by: srdconsulting
11 Replies

4. Shell Programming and Scripting

Special Char in Data file

Hi All, I have a data file in UNIX which i am trying to load into Oracle table using Oracle SQL Loader. The problem is, one of the filed contains special character (ex: Square). And due to this reason, my script fails. Could you please let me know, how to identify which character is... (1 Reply)
Discussion started by: Amit.Sagpariya
1 Replies

5. Shell Programming and Scripting

Remove special char from end of the file

Hi I am working on a bash script and would know how to use cut or sed to remove (F/.M/d h) from a text file. Before 1 text to save (F/.M/d h) after 1 text to save Thanks in advance (5 Replies)
Discussion started by: pelle
5 Replies

6. Shell Programming and Scripting

Move file based on filename

Hi All I need a script to manipulate files based on a filename: example filename: 66600_042706.pdf the script will create a directory 66000 only if this directory is not existing. If that directory is existing it will just move the file to 66000/666000_042706.pdf in addition, i want to... (4 Replies)
Discussion started by: aemestech
4 Replies

7. Shell Programming and Scripting

remove the special characters and move the file into another server

(5 Replies)
Discussion started by: number10
5 Replies

8. UNIX for Advanced & Expert Users

Stty and copy special character

Hello, I do have a little issue here and Google doesn't give me any solution @this moment. In HP UX Vi editor: I want to place this character: ® I copied it from internet or for example Word Special Symbols. But how do I paste it in Vi? Many thanks in advance :) Sincerely, Arjan (7 Replies)
Discussion started by: velde_van_der_a
7 Replies

9. Shell Programming and Scripting

To search distinct special char in file

hi, i need to search distinct special character from a file which is a pipe delimited from a specific column for eg: input file.txt aa|bb|cc|$abc aa|bb|ccc|#abol bb|xss|ddd|$xyz nn|yyy|qqq|=qqqq abe|qqq|yyy|=aaa aaa|yyy|zzzz|#aaaa . . . my desired output $ (10 Replies)
Discussion started by: rohit_shinez
10 Replies

10. Shell Programming and Scripting

^M special character in Filename

Hi All, Special character ? is added in between filename. Am not able to figure our why this is happening. In my Development environment special characters are not present. This issue is happening in the higher environment. It would be helpful if somebody can tell what are the possible... (3 Replies)
Discussion started by: weknowd
3 Replies
XEN-DELETE-IMAGE(8)					 Perl Programmers Reference Guide				       XEN-DELETE-IMAGE(8)

NAME
xen-delete-image - Delete previously created Xen instances. SYNOPSIS
xen-delete-image [options] [--hostname=]imageName1 [--hostname=]imageName2 Help Options: --help Show help information. --manual Read the manual for this script. --version Show the version information and exit. --verbose Show diagnostic output. General options: --dir Specify the output directory where images were previously saved. --evms Specify the EVMS container to use. --lvm Specify the LVM volume to use. Specifying hosts: --hostname Specify the image name to delete. Testing options: --test Don't complain if we're not invoked by root. OPTIONS
--dir Specify the output directory where images were previously saved. --evms Specify the EVMS container where images were previously saved. --help Show help information. --hostname Specify the hostname to delete. --lvm Specify the LVM volume group where images were previously saved. --manual Read the manual for this script. --test Do not complain, or exit, if the script is not executed by the root user. --version Show the version number and exit. DESCRIPTION
xen-delete-image is a simple script which allows you to delete Xen instances which have previously been created by xen-create-image. You must be root to run this script as it removes the Xen configuration file from /etc/xen and potentially removes LVM and EVMS volumes. (When invoked with the '--test' flag the script will continue running, but will fail to remove anything which the user does not have permission to delete.) LOOPBACK EXAMPLE
Assuming that you have three images 'foo', 'bar', and 'baz', stored beneath /home/xen the first two may be deleted via: xen-delete-image --dir=/home/xen foo bar You may also delete them by running: xen-delete-image --dir=/home/xen --hostname=foo --hostname=bar (The matching Xen configuration files beneath /etc/xen will also be removed.) LVM EXAMPLE
Assuming that you have the volume group 'skx-vol' containing three Xen instances 'foo', 'bar', and 'baz' the first two may be deleted via: xen-delete-image --lvm=skx-vol foo bar This will remove the volumes 'foo-disk', 'foo-swap', 'bar-disk', and 'bar-swap'. Note that if the images were created with "--noswap" then the swap volumes will not be present, so will not need to be deleted. The Xen configuration files will also be removed from beneath /etc/xen. EVMS EXAMPLE
Assuming that you have the container 'mycontainer' containing three Xen instances 'foo', 'bar', and 'baz' the first two may be deleted via: xen-delete-image --evms=lvm2/mycontainer --hostname=foo --hostname=bar This will remove the volumes 'foo-disk', 'foo-swap', 'bar-disk', and 'bar-swap'. Note that if the images were created with "--noswap" then the swap volumes will not be present, so will not need to be deleted. The Xen configuration files will also be removed. AUTHORS
Steve Kemp, http://www.steve.org.uk/ Axel Beckert, http://noone.org/abe/ StA~Xphane Jourdois LICENSE
Copyright (c) 2005-2009 by Steve Kemp, (c) 2010 by The Xen-Tools Development Team. All rights reserved. This module is free software; you can redistribute it and/or modify it under the same terms as Perl itself. The LICENSE file contains the full text of the license. 4.3.1 2012-06-30 XEN-DELETE-IMAGE(8)
All times are GMT -4. The time now is 11:36 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy