1
vote
4answers
44 views

How to rename a lot of files in bash shell?

Sorry for the question. I searched the internet a lot, but couldn't find an answer which worked (though there were a lot of suggestions). So, I want to rename A LOT of files. Writing all file names ...
0
votes
1answer
40 views

Is it possible to open a port for listening without netcat?

I have a need for a Linux system to listen on a TCP port and dump what it receives to a file and/or stdout. The system does not have netcat installed. I have root permissions, but am not allowed to ...
0
votes
1answer
39 views

TC command via webpage as a sudo

The main goal- run a tc command via webpage, starting with: tc qdisc del root dev eth0 (deletes all the filters) Following Simple linux commands from a webpage I am trying to add a tc command, but ...
-1
votes
1answer
22 views

editing column of a text file

abc.txt consists of two column data as 1 A1021 2 A1021 3 A1022 4 A1022 I want another test file, say pqr.txt (replacing A1021 by 1 and A1022 by 2 and so on). I used the following usual perl ...
1
vote
1answer
43 views

How to get list of process ids that are in a given group id

Going by the man page, I would expect this to work: ps ah -o pid,pgrp -G 18322 But this shows exactly the same list as without the -G arguments. I want a saner way to produce this output: ps ah -o ...
1
vote
1answer
38 views

Script not running as cronjob

I got a script which runs in a cronjob as root. The problem is that the addgroup command would output "Command not found" when it gets executed by the script. #!/usr/bin/perl $datei = `ls ...
-1
votes
1answer
31 views

Get value on perl script from another perl script [closed]

I have two perl scripts. The first perl script call another perl script, and then I want to get the result from the other script and use it in the first script to made a condition. I use: ...
0
votes
0answers
31 views

open a new screen in linux, no access to perl local library

I added my perl local library to my shell startup script (.bashrc) and when I start a terminal in linux: $ echo $PERL5LIB /home/perl5/lib/perl5:/usr/share/vcftools/perl BUT when I open a new ...
0
votes
0answers
33 views

Bugzilla mail template not supported in outlook

I have installed bugzilla 4.2 version in linux centos 6.4. Everything working fine except mail format. It is not supporting in outlook. whenever we raising the bug from bugzilla mail delivered in ...
0
votes
1answer
106 views

Find number in string and replace it

I wrote C++ code and now I want to replace the number in a string by using shell scripts. The part that needs to be replaced: if (random<=90) How I can change the 90 from a shell script? I ...
0
votes
1answer
69 views

Rename files from in1.jpg, in2.jpg, in3.jpg, etc to out0001.jpg, out0002.jpg, out0003.jpg etc using perl script `rename`

I would like to rename a large number files with names in1.jpg, in2.jpg, in3.jpg, etc to out0001.jpg, out0002.jpg, out0003.jpg, etc. Grateful if somebody would suggest a solution using the perl script ...
0
votes
0answers
181 views

Installing R core rpms on centos - Need a best way to resolve dependencies

I am newbie to the Linux. I need to know the best way to handle the dependencies. The issue is, I need to install R - core and R - dev (R language packages) on an platenized centos linux host on ...
0
votes
0answers
25 views

PERL executable size getting reduced automatically after few days

On one of my RHEL 5 machine, there is one PERL executable which runs under cronjob at frequent intervals of time. The strange thing observed is PERL executable size is getting reduced automatically ...
0
votes
1answer
90 views

SortTV perl script error

I'm trying to use a perl script named SortTV (http://sourceforge.net/projects/sorttv/) Every dependencies is installed but I got an error & can't understood it... It's not a specific problem of ...
0
votes
1answer
748 views

Install XML::Parser

I'm trying to install some perl module but got strange error. sudo cpanm XML::Parser cp Parser/Encodings/iso-8859-5.enc blib/lib/XML/Parser/Encodings/iso-8859-5.enc make[1]: Entering directory ...
0
votes
1answer
303 views

Install perl module with dependencies

I'm trying to install a Perl module like this : pi@raspbmc:~$ sudo cpan HTTP::Date Cpan get the file Checksum is ok uncompressed successfully But I got this error : Using Tar:/bin/tar xf ...
0
votes
1answer
92 views

how to get Geo::Coder::Many with cpan?

Ubuntu is installed for development of a Perl project. aptitude search Geo-Coder i libgeo-coder-googlev3-perl - Perl module providing access to Google Map Aptitude does not refer to ...
0
votes
2answers
38 views

Where to place an executable Perl script?

I'm now planning a solution that has to call a script that's running on a Linux \UNIX host. I'd prefer to place that script in a folder that exists in all kinds of Linux and UNIX. This helps me to ...
0
votes
0answers
53 views

Can't Parsing Log Linux File Today

I'd like to monitor my linux logs and pull information from the logs to process the files that activities of the workers I do, in my company. #!/bin/bash #if [[ -z "$1" ]]; then # echo ...
1
vote
1answer
550 views

How can I fix broken apt/perl libraries?

I've got a Raspberry Pi set up as a web server, everything all working well until 5 mins ago, and I seem to have messed up man-db, apt or some perl library. apt-get doesn't seem to be updating and ...
0
votes
0answers
53 views

Error installing mail server

I'm trying to get my own mail server running, but I'm having some troubles with it. It seems like there's an error regarding CGI for Perl. I don't understand the error as I'm quite sure I installed ...
2
votes
1answer
85 views

Could not perform immediate configuration on 'perl'

I'm trying to upgrade a debian squeeze system to wheezy. I've done an apt-get update && apt-get -V upgrade on squeeze, then changed my source.list to reference wheezy not squeeze. then, ...
7
votes
1answer
1k views

Shell script to find all types of files in a directory with their count

I want to write a shell script or alias to find the number of different types of files in a directory. For example, sample output of script should be: *.h 20 *.c 40 *.cpp 10 Makefile 3
2
votes
1answer
94 views

Perl program won't run on arm6, but it runs on my 64bit computer

I'm trying to run [pisg][1] on my raspberry pi, which is running archlinux arm, and every time I try to run it, I get: Root ~>pisg -cf pisg.conf Warning: Couldn't parse -cfg option Could ...
10
votes
2answers
664 views

How to cut a file to a given size under Linux?

I want to shrink a file's size by brute-force, that is, I don't care about the rest, I just want to cut the file, say by half, and discard the rest. The first thing that comes to mind is Perl's ...
2
votes
2answers
1k views

How to install a 32 bit version of perl on 64 bit Cent OS server?

I want to install 32 bit version of perl on my Cent OS server which is of course of 64 bit..Output of perl -v is [root@M-229 ~]# perl --version This is perl, v5.10.1 (*) built for ...
0
votes
0answers
218 views

Uninstall Bugzilla in Linux, and re install it with previous mysql database

I installed Bugzilla on a Centos 5 system with perl version 5.8.8, by download Bugzilla tar ball, execute the perl scripts came with it, create database and went through other steps. Questions: Is ...
0
votes
1answer
84 views

Fedora bleeding edge Perl repo?

Are there any Fedora YUM repositories that would contain the very latest stable version of Perl (at the time of writing, 5.18.0)? The Fedora site says that won't even be shipped stock until Fedora ...
0
votes
3answers
131 views

my perl scripts that use Net:Pcap dont work when i port them onto a vm on my server

I am trying to run a perl script that i have scripted to dump the packets from my network, i am using the Net:Pcap and netpacket modules. They are working fine on my and my friend's laptop. but when ...
1
vote
0answers
98 views

Permissions tar extraction to nfs share from a Perl script

As part of an installation procedure of a piece of software, I use: curl -s <url-to-targz> | tar -p -x -z -C / inside a Perl script (I use qx($command) or system($command), either will ...
1
vote
1answer
97 views

Backup many files by keeping all old versions

My question is about saving many files from many directories in only one directories by keeping all old versions of the files. I have about 10 directories with very similar files (10 backup ...
0
votes
1answer
211 views

The outputs of ps and top do not match

I have a situation where I have a process, say script.pl (here it is), which seems to stick around in the output to ps auxw | grep script.pl, sometimes when load is heavy it sticks around for several ...
0
votes
1answer
283 views

How do I make my Perl scripts act like normal programs on Linux

Perl programs I've written earlier were simple text processing scripts, for executing them I use to use terminal. Now I am learning GUI programming(I want to make some games as a hobby), using Tcl/TK ...
1
vote
2answers
106 views

Do I need a cloud server?

I have a certain setup on my local Linux machine and I wonder how can I convert it to a web service platform. What I have is: Command line Perl application which periodically downloads certain data ...
0
votes
1answer
186 views

Multi-threaded execution of simple perl/python script

Some years ago a friend created a 'benchmark' (Note: Not a benchmark) by which wouldwhich we measure one raw aspect of computing power. Namely how fast (or indeed slowly) the computer could count to ...
0
votes
1answer
32 views

Installing a CPAN module using a remote compiler

I need to install the XML::Parser module. Unfortunately, that package uses expat. Due to security concerns, I am not allowed to install the dev package of expat. making the CPAN Module fail to ...
1
vote
2answers
131 views

Are there any Linux distributions which have Perl 6 as the default/only Perl version?

The title pretty much says it all. In the same way that Arch Linux has Python 3 as the built-in/main version of Python, are there any Linux/Unixish distros that have done the same with Perl 6? I ...
2
votes
1answer
545 views

Change my terminal's character set in Ubuntu

I would like to process with perl some files in Greek in which the character encoding is Greek (ISO-8859-7) but my terminal doesn't support such an encoding. Can I add it somehow?
0
votes
2answers
89 views

For loop with conditions

I have a script that adds user on many server. Since I'm adding on many server(s) I am using for loop. Below are the output when user is successfully added. 0,22529,User added. If the user is not ...
0
votes
2answers
244 views

Handling MS office documents on Linux without root access

I have a linux hosting account with Godaddy (Centos 5.5), and I am developing an application to process users MS Office documents. I have found solutions such as antiword, unoconv, catdoc, Apach ...
0
votes
1answer
212 views

Identify text/ASCII files in Linux/Solaris

I have a little project to build a bash script that searches the OS (Linux/Solaris) for the current IP address in files, and replaces them with another IP address. The problem is that IP address ...
0
votes
1answer
171 views

Check file name and filter it based on the date

I have many files one of my scripts generate daily. The file name structure resembles: capacity_data_2012-12-02.txt , capacity_data_2012-12-03.txt and so on... I want to create a script which would ...
1
vote
1answer
432 views

Add, replace or delete something/everything between two strings with regexxer

I'm using regexxer to translate an application that use .php files. In accordance to the webpage it's based on usage and syntax of Perl regular expressions. It looks more to be applied to Perl code. ...
0
votes
2answers
349 views

creating CDF data using bash or awk or perl

we have some data like: 12 0 13 0 20 0 25 1 64 4 77 1 89 100 1201 204 I'd like to get this output: 3 0 5 1 6 4 7 100 8 204 explanation: we have 3 AS(autonomous systems) that have degree of ...
2
votes
1answer
1k views

Counting occurrences in first column of a file

We have this file: 1 2 1 3 1 2 3 3 52 1 52 300 and 1000 more. I want to count the number of times each value occurs in the first column. 1 3 3 1 52 2 This means we saw 1 three times. How ...
4
votes
3answers
89 views

Output numbers from a file in a different order

I have a file that contains: 1 2 3 4 1 3 5 4 8 3 2 1 Each line has a different number of digits. And there are 1000 more like this. I want the output like this: 1 2 2 3 3 4 4 0 1 3 3 5 5 4 4 8 8 ...
6
votes
3answers
256 views

Remove duplicates in each line of a file

How can I remove duplicates in each line, for example here? 1 1 1 2 1 2 3 5 5 4 1 2 3 3 I'd like to get this output: 1 2 3 5 4 1 2 3 There are lots of lines (100,000) and in each line I want ...
0
votes
1answer
753 views

In Fedora, Perl program cannot find Time::Piece library

I have a Perl program named /usr/bin/octbatch running as a script on Fedora 17 Linux. When I run this command: /usr/bin/octbatch I get the error: Can't locate Time/Piece.pm in @INC (@INC ...
0
votes
1answer
225 views

script to convert GB to TB

I have (multiple) files like below list. Few of them has both the values in TB and couple of files in GB. Now if you clearly see the file output there are two rows with Total capacity and Capacity ...
1
vote
2answers
106 views

what is (3pm), when I run apropos Unicode in see entries like this Unicode::CharName (3pm)

apropos unicode Pango::ScriptIter (3pm) - used to break a string of Unicode into runs by text Unicode::CharName (3pm) - Look up Unicode character names Unicode::Map (3pm) - (unknown subject) ...