# FAQ

**URL:** https://community.unix.com/c/faq/13.md

[Latest](https://community.unix.com/latest.md) · [Categories](https://community.unix.com/categories.md)

---

## [About the FAQ category](https://community.unix.com/t/about-the-faq-category/138052)

<div class="topic-metadata">

**Author:** [@system](https://community.unix.com/u/system)\
**Replies:** 0\
**Last updated:** [March 15, 2020, 7:14pm UTC](https://community.unix.com/t/about-the-faq-category/138052 "2020-03-15T19:14:06Z")

</div>

Frequency asked questions.

---

## [Not able to attach a particular excel report in unix server using mailx command](https://community.unix.com/t/not-able-to-attach-a-particular-excel-report-in-unix-server-using-mailx-command/385849)

<div class="topic-metadata">

**Author:** [@Meena\_Vivek1](https://community.unix.com/u/Meena_Vivek1)\
**Replies:** 4\
**Last updated:** [March 17, 2022, 10:32am UTC](https://community.unix.com/t/not-able-to-attach-a-particular-excel-report-in-unix-server-using-mailx-command/385849 "2022-03-17T10:32:06Z")

</div>

Not able to attach a particular excel report in unix server using mailx command . Is there any reason why the excel cannot be sent by email? This has worked in past but suddenly it is not working.

---

## [How clustering postfix?](https://community.unix.com/t/how-clustering-postfix/385008)

<div class="topic-metadata">

**Author:** [@bita](https://community.unix.com/u/bita)\
**Replies:** 8\
**Last updated:** [January 11, 2022, 6:59pm UTC](https://community.unix.com/t/how-clustering-postfix/385008 "2022-01-11T18:59:15Z")

</div>

hi we have one postfix on Ubuntu server but we decided to create clustering 2 postfix server that both of them read from one source or replicated to getherdata and configuration . do you have any one idea or solution f…

---

## [How to merge data in 2 csv files using shell script?](https://community.unix.com/t/how-to-merge-data-in-2-csv-files-using-shell-script/377958)

<div class="topic-metadata">

**Author:** [@SwethaGorantla](https://community.unix.com/u/SwethaGorantla)\
**Replies:** 2\
**Last updated:** [April 14, 2020, 4:07am UTC](https://community.unix.com/t/how-to-merge-data-in-2-csv-files-using-shell-script/377958 "2020-04-14T04:07:23Z")

</div>

csv1: StoreID Emailcount 2000 3 2001 2 csv2: StoreID Slotcount 2000 100 2001 120 Output required as below StoreID Emailcount Slotcount 2000 3 …

---

## [Manipulate data in CSV file using Shell script](https://community.unix.com/t/manipulate-data-in-csv-file-using-shell-script/377954)

<div class="topic-metadata">

**Author:** [@SwethaGorantla](https://community.unix.com/u/SwethaGorantla)\
**Replies:** 3\
**Last updated:** [April 13, 2020, 10:42pm UTC](https://community.unix.com/t/manipulate-data-in-csv-file-using-shell-script/377954 "2020-04-13T22:42:28Z")

</div>

HI, Can you guys please help me in creating Pivot table for below data using shell script? Location\_id| Effective\_date| Picking\_limit ------- | ---------------- | ----------: 2000| 04/04/2020| 120 2001| 04/04/202…

---

## [NETEM - fq\_codel and pfifo\_fast change/add tc rule](https://community.unix.com/t/netem-fq-codel-and-pfifo-fast-change-add-tc-rule/376307)

<div class="topic-metadata">

**Author:** [@Priya\_Amaresh](https://community.unix.com/u/Priya_Amaresh)\
**Replies:** 4\
**Last updated:** [September 20, 2019, 1:58pm UTC](https://community.unix.com/t/netem-fq-codel-and-pfifo-fast-change-add-tc-rule/376307 "2019-09-20T13:58:06Z")

</div>

HI, I am trying to understand netem operation over Linux when I issued tc show command i see as follows: ing:~ tc qdisc show dev en1 qdisc mq 0: root qdisc fq\_codel 0: parent :18 limit 10240p flows 1024 quantum 1514 t…

---

## [Compare date in .txt with system date and remove if it's lesser than system date](https://community.unix.com/t/compare-date-in-txt-with-system-date-and-remove-if-its-lesser-than-system-date/374777)

<div class="topic-metadata">

**Author:** [@Stuti](https://community.unix.com/u/Stuti)\
**Replies:** 1\
**Last updated:** [February 7, 2019, 5:16am UTC](https://community.unix.com/t/compare-date-in-txt-with-system-date-and-remove-if-its-lesser-than-system-date/374777 "2019-02-07T05:16:08Z")

</div>

I m working on shell scripting and I m stuck where in my .txt file there is column as expiry date and I need to compare that date with system date and need to remove all the rows where expiry date is less than system dat…

---

## [Combine the two files into one file from two Linux servers](https://community.unix.com/t/combine-the-two-files-into-one-file-from-two-linux-servers/374342)

<div class="topic-metadata">

**Author:** [@reminisce](https://community.unix.com/u/reminisce)\
**Replies:** 1\
**Last updated:** [December 12, 2018, 11:53am UTC](https://community.unix.com/t/combine-the-two-files-into-one-file-from-two-linux-servers/374342 "2018-12-12T11:53:06Z")

</div>

Hi Guys, Can anyone provide the solution /commands to combine the files which are in two different linux servers into a file. Thanks, Reminisce

---

## [Combine the two files from two Linux servers into one file](https://community.unix.com/t/combine-the-two-files-from-two-linux-servers-into-one-file/374339)

<div class="topic-metadata">

**Author:** [@reminisce](https://community.unix.com/u/reminisce)\
**Replies:** 1\
**Last updated:** [December 12, 2018, 9:06am UTC](https://community.unix.com/t/combine-the-two-files-from-two-linux-servers-into-one-file/374339 "2018-12-12T09:06:21Z")

</div>

Hi Guys, Can anyone please suggest the commands to combine two files data from two different linux servers . Reminisce

---

## [Not able understand logic and working](https://community.unix.com/t/not-able-understand-logic-and-working/373680)

<div class="topic-metadata">

**Author:** [@scriptor](https://community.unix.com/u/scriptor)\
**Replies:** 1\
**Last updated:** [September 12, 2018, 8:59am UTC](https://community.unix.com/t/not-able-understand-logic-and-working/373680 "2018-09-12T08:59:20Z")

</div>

not understand

---

## [Command to find if a server is a VIP or normal server](https://community.unix.com/t/command-to-find-if-a-server-is-a-vip-or-normal-server/373131)

<div class="topic-metadata">

**Author:** [@Usha\_Rajesh](https://community.unix.com/u/Usha_Rajesh)\
**Replies:** 1\
**Last updated:** [July 11, 2018, 1:59pm UTC](https://community.unix.com/t/command-to-find-if-a-server-is-a-vip-or-normal-server/373131 "2018-07-11T13:59:37Z")

</div>

I have a list of servers which has both VIP and normal server. Is there a command to identify which server is a VIP and which is a normal server? Please help.

---

## [How to get defined precision after arithmetic operation using syncsort?](https://community.unix.com/t/how-to-get-defined-precision-after-arithmetic-operation-using-syncsort/371360)

<div class="topic-metadata">

**Author:** [@pumrao](https://community.unix.com/u/pumrao)\
**Replies:** 0\
**Last updated:** [March 16, 2018, 1:21am UTC](https://community.unix.com/t/how-to-get-defined-precision-after-arithmetic-operation-using-syncsort/371360 "2018-03-16T01:21:18Z")

</div>

I have to do some arithmetic operation on Field 8 which is calculated by Field 9/Field 7 Suppose i have data like : 0800123456|JAN|2017|JAN|2018|0800123456|0|0.0000|0.00| 0800234567|JAN|2017|JAN|2018|0800234567|4|2.581…

---

## [How to run the files in Linux shell scipt?](https://community.unix.com/t/how-to-run-the-files-in-linux-shell-scipt/369934)

<div class="topic-metadata">

**Author:** [@pavand](https://community.unix.com/u/pavand)\
**Replies:** 1\
**Last updated:** [December 18, 2017, 4:27pm UTC](https://community.unix.com/t/how-to-run-the-files-in-linux-shell-scipt/369934 "2017-12-18T16:27:48Z")

</div>

I have a homework and I tried to work on this but unable to find the solution. Can someone help me how to resolve the issue. I have a package file and it contains text file as prod.ame300\_000001.101414145111.A.txt. In…

---

## [Fixed width file issue and resolutions](https://community.unix.com/t/fixed-width-file-issue-and-resolutions/367505)

<div class="topic-metadata">

**Author:** [@santoshkm](https://community.unix.com/u/santoshkm)\
**Replies:** 2\
**Last updated:** [July 19, 2017, 8:28am UTC](https://community.unix.com/t/fixed-width-file-issue-and-resolutions/367505 "2017-07-19T08:28:17Z")

</div>

I have a fixed width file with no separators , but the file has JUNK characters in it and i know how to remove it. but in few cases these junk characters having created a mess by splitting single row into 2 or 3 rows. I…

---

## [Read a json file passed as cmd line argument](https://community.unix.com/t/read-a-json-file-passed-as-cmd-line-argument/367193)

<div class="topic-metadata">

**Author:** [@RGRT](https://community.unix.com/u/RGRT)\
**Replies:** 2\
**Last updated:** [June 27, 2017, 2:40am UTC](https://community.unix.com/t/read-a-json-file-passed-as-cmd-line-argument/367193 "2017-06-27T02:40:13Z")

</div>

usage: myscript.sh config.json config.json: { "HOST":"abc", "DB\_NM":"xyz", "USR\_NM":"asd", "PWD":"xxx", ......... ......... ......... ........ } myscript.sh: \*\* #HOW TO SOURCE THE c…

---

## [Syntax error near unexpected token \`('](https://community.unix.com/t/syntax-error-near-unexpected-token/366483)

<div class="topic-metadata">

**Author:** [@ranabhavish](https://community.unix.com/u/ranabhavish)\
**Replies:** 1\
**Last updated:** [May 9, 2017, 8:10am UTC](https://community.unix.com/t/syntax-error-near-unexpected-token/366483 "2017-05-09T08:10:04Z")

</div>

I have 2 files like a.txt and b.txt and the content is as below cat a.txt 810750125 117780 /BSCSQAT4A/bscsqat4a/lib/jar/wclt\_common.jar 1803152428 13300 /BSCSQAT4A/bscsqat4a/lib/jar/WFMSSupportTool.jar 2663502779 67049…

---

## [How to split a dat file based on another file ni UNIX?](https://community.unix.com/t/how-to-split-a-dat-file-based-on-another-file-ni-unix/366351)

<div class="topic-metadata">

**Author:** [@pogo](https://community.unix.com/u/pogo)\
**Replies:** 1\
**Last updated:** [May 1, 2017, 4:52am UTC](https://community.unix.com/t/how-to-split-a-dat-file-based-on-another-file-ni-unix/366351 "2017-05-01T04:52:06Z")

</div>

i have two files , one is var.txt and another res.dat file var.txt contains informaton like below date,request,sales,item 20171015,1,123456,216 20171015,1,123456,217 20171015,2,345678,214 20171015,3,456789,218 a…

---

## [Calling a Sybase Stored procedure from a UNIX Script](https://community.unix.com/t/calling-a-sybase-stored-procedure-from-a-unix-script/364693)

<div class="topic-metadata">

**Author:** [@Arun619](https://community.unix.com/u/Arun619)\
**Replies:** 1\
**Last updated:** [January 24, 2017, 3:41am UTC](https://community.unix.com/t/calling-a-sybase-stored-procedure-from-a-unix-script/364693 "2017-01-24T03:41:22Z")

</div>

Hi, I am new to shell scripting and Sybase database i need a help that i try to execute a SYBASE stored procedure from a Unix shell script and wanna write the output of the SP into a Text File.somehow i try to find a sol…

---

## [Running Turbo-cad and circuit wizard programmes.](https://community.unix.com/t/running-turbo-cad-and-circuit-wizard-programmes/364321)

<div class="topic-metadata">

**Author:** [@Alfred\_Kruger](https://community.unix.com/u/Alfred_Kruger)\
**Replies:** 1\
**Last updated:** [January 1, 2017, 6:52am UTC](https://community.unix.com/t/running-turbo-cad-and-circuit-wizard-programmes/364321 "2017-01-01T06:52:13Z")

</div>

Hi. i am new to Linux. i have a Turbo-cad and circuit wizard programme on CD that I want to install and run. I keep getting the message I do not have an auto-run programme. Do I need to install specific drivers for this?…

---

## [How do I send email?](https://community.unix.com/t/how-do-i-send-email/363287)

<div class="topic-metadata">

**Author:** [@gracec](https://community.unix.com/u/gracec)\
**Replies:** 0\
**Last updated:** [October 30, 2016, 3:53am UTC](https://community.unix.com/t/how-do-i-send-email/363287 "2016-10-30T03:53:52Z")

</div>

The answers are: Open Gmail In the Top left, click, compose In the top field add recipients, if you want, you can also add recipients in the CC and bcc fields Add a subject Write your message At the bottom of the page,…

---

## [Get all business days from week including today](https://community.unix.com/t/get-all-business-days-from-week-including-today/363132)

<div class="topic-metadata">

**Author:** [@abhii](https://community.unix.com/u/abhii)\
**Replies:** 1\
**Last updated:** [October 21, 2016, 3:04am UTC](https://community.unix.com/t/get-all-business-days-from-week-including-today/363132 "2016-10-21T03:04:52Z")

</div>

I am trying to get last 5 business day \[excluding sat and sun\]. trying for d in Mon Tue Wed Thu Fri do date +%Y%m%d -d "last $d" done gives me \[provided\] date Thu Oct 20 23:56:26 EDT 2016 20161017 20161018 20161019 2…

---

## [Subtracting two files](https://community.unix.com/t/subtracting-two-files/361923)

<div class="topic-metadata">

**Author:** [@beginner\_99](https://community.unix.com/u/beginner_99)\
**Replies:** 5\
**Last updated:** [August 12, 2016, 8:21pm UTC](https://community.unix.com/t/subtracting-two-files/361923 "2016-08-12T20:21:55Z")

</div>

Hi, I want to subtract 2 files and save the remaining text in another file. Lets say, \`\` Hello Happy // Hi \* Hungry File2 Happy Hi Output Hello // \* Hungry I do not want to remove the whole line. Just need the …

---

## [How to prevent sed command removing whole line?](https://community.unix.com/t/how-to-prevent-sed-command-removing-whole-line/361931)

<div class="topic-metadata">

**Author:** [@beginner\_99](https://community.unix.com/u/beginner_99)\
**Replies:** 3\
**Last updated:** [August 12, 2016, 5:19pm UTC](https://community.unix.com/t/how-to-prevent-sed-command-removing-whole-line/361931 "2016-08-12T17:19:09Z")

</div>

hello, I’m using sed command to extract the text between 2 special characters which are /\* and \*/ I used following command to do this. sed -n '/\\/\\\*/,/\\\*\\//p' file.txt But if the file.txt contains a line something…

---

## [Help me in awk or sed in UNIX](https://community.unix.com/t/help-me-in-awk-or-sed-in-unix/360823)

<div class="topic-metadata">

**Author:** [@RJG](https://community.unix.com/u/RJG)\
**Replies:** 1\
**Last updated:** [June 7, 2016, 8:51am UTC](https://community.unix.com/t/help-me-in-awk-or-sed-in-unix/360823 "2016-06-07T08:51:24Z")

</div>

I have a fixed length file that looks like a@ a00 a00000 a00 a000000 a00 a0000 a0000 a00000000 a01 a@ a1 a2 a11 a22 a12 a13 a44 a45 a54 a65 a76 a77 a@ a1 a3 a6 a7 …

---

## [Add string to parentheses](https://community.unix.com/t/add-string-to-parentheses/359609)

<div class="topic-metadata">

**Author:** [@steve120](https://community.unix.com/u/steve120)\
**Replies:** 2\
**Last updated:** [April 7, 2016, 2:20am UTC](https://community.unix.com/t/add-string-to-parentheses/359609 "2016-04-07T02:20:41Z")

</div>

Suppose I have this code : int main () { int i = NULL; /\* incorrect \*/ return 0; } and I want to put the word between the two parentheses like this : int main (void) { int i = NULL; /\* incorrect \*/ return…

---

## [Error when compiling using cygwin](https://community.unix.com/t/error-when-compiling-using-cygwin/359601)

<div class="topic-metadata">

**Author:** [@steve120](https://community.unix.com/u/steve120)\
**Replies:** 6\
**Last updated:** [April 6, 2016, 12:14pm UTC](https://community.unix.com/t/error-when-compiling-using-cygwin/359601 "2016-04-06T12:14:04Z")

</div>

I tried to compile the files in basic\_dump\_ex using cygwin : /cygdrive/c/WpdPack/Examples-pcap/basic\_dump\_ex \*\*$make \*\* but I got this : cc -g -O -mno-cygwin -I ../../include -c -o basic\_dump\_ex.o basic\_dump\_ex.c cc…

---

## [Simultaneously try to execute commands after connecting to remote account to one account](https://community.unix.com/t/simultaneously-try-to-execute-commands-after-connecting-to-remote-account-to-one-account/358934)

<div class="topic-metadata">

**Author:** [@kishored005](https://community.unix.com/u/kishored005)\
**Replies:** 1\
**Last updated:** [March 3, 2016, 10:00am UTC](https://community.unix.com/t/simultaneously-try-to-execute-commands-after-connecting-to-remote-account-to-one-account/358934 "2016-03-03T10:00:44Z")

</div>

I have made password less connection to my remote account. and i tried to execute commands at a time. but i am unable to execute the commands. ssh $ACCOUNT\_DETAILS@$HOST\_DETAILS cd ~/JEE/\*/logs/

---

## [Help me, write a bash script to delete parent entry with all their child entry in LDAP UNIX server](https://community.unix.com/t/help-me-write-a-bash-script-to-delete-parent-entry-with-all-their-child-entry-in-ldap-unix-server/356918)

<div class="topic-metadata">

**Author:** [@Chand](https://community.unix.com/u/Chand)\
**Replies:** 1\
**Last updated:** [November 22, 2015, 2:41am UTC](https://community.unix.com/t/help-me-write-a-bash-script-to-delete-parent-entry-with-all-their-child-entry-in-ldap-unix-server/356918 "2015-11-22T02:41:25Z")

</div>

Hi All, Please help me and guide me to write a bash/shell script on Linux box to delete parent entry with all their child entries. example: Parent is : dn: email=yogesh.kumar@wipro.com, o=wipro, o=in child is: dn: c…

---

## [How to replace value of password tag in xml with blanks when special characters are there?](https://community.unix.com/t/how-to-replace-value-of-password-tag-in-xml-with-blanks-when-special-characters-are-there/356368)

<div class="topic-metadata">

**Author:** [@saroopkris85](https://community.unix.com/u/saroopkris85)\
**Replies:** 7\
**Last updated:** [October 27, 2015, 3:35pm UTC](https://community.unix.com/t/how-to-replace-value-of-password-tag-in-xml-with-blanks-when-special-characters-are-there/356368 "2015-10-27T15:35:03Z")

</div>

Hi All, I am trying to replace the values inside \<password\> tag in an xml file but it doesn’t replace certain passwords: For eg: Server/home/sperinc\>cat TextXML.txt \<appIds\> \<entry name="AccountXref"\> …

---

## [Sending a mail with different attachment in AIX](https://community.unix.com/t/sending-a-mail-with-different-attachment-in-aix/356017)

<div class="topic-metadata">

**Author:** [@Swapnil\_Mawle](https://community.unix.com/u/Swapnil_Mawle)\
**Replies:** 1\
**Last updated:** [October 13, 2015, 7:17am UTC](https://community.unix.com/t/sending-a-mail-with-different-attachment-in-aix/356017 "2015-10-13T07:17:08Z")

</div>

How to Send a mail with multiple attachment also differenet extension using uuencode in AIX. Can you please help me. Its so urgent. Thanks. Regards, Swapnil ---------- Post updated at 05:37 AM ---------- Previous up…

[Next page](https://community.unix.com/c/faq/13.md?page=1)
