LinuxQuestions.org
Support LQ: Use code LQ3 and save $3 on Domain Registration
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 02-17-2011, 02:34 PM   #1
bino25
Member
 
Registered: Dec 2010
Posts: 45

Rep: Reputation: 11
serious script help needed


I am in need of some serious help. I am a windows admin that was thrown the responsibility of our unix servers when our admin walked out on Tuesday (I was the only person that had ever used unix before).

Anyway, there is a script (attached txt file) our oracle users are calling (which I do not know unix scripting), and the email portion of it is failing. If they enter jsmith@company.com it will work, but if they enter the newly created exchange alias GROUPALIAS@company.com, it never sends the email (maybe the capital letters make a difference?)If anybody could help me with this, I would greatly appreciate it. The script is about 190 lines long (I changed line 24 to generic).

Thanks so much for whoever can help!!!
Attached Files
File Type: txt email_list.txt (9.1 KB, 24 views)
 
Old 02-17-2011, 02:46 PM   #2
corp769
LQ Guru
 
Registered: Apr 2005
Posts: 5,817

Rep: Reputation: 1002Reputation: 1002Reputation: 1002Reputation: 1002Reputation: 1002Reputation: 1002Reputation: 1002Reputation: 1002
Technically case does not matter, so why would you capitalize it in the first place?
 
Old 02-17-2011, 02:52 PM   #3
bino25
Member
 
Registered: Dec 2010
Posts: 45

Original Poster
Rep: Reputation: 11
Because that's they way it was presented to me didn't know if that would matter for what the script is looking for
 
Old 02-17-2011, 03:21 PM   #4
Tinkster
Moderator
 
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 23,066
Blog Entries: 11

Rep: Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910
What's the output of the script? It's hard to look for something
specific w/o the messages the script generates.


Cheers,
Tink
 
Old 02-17-2011, 08:57 PM   #5
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Centos 6.8, Centos 5.10
Posts: 17,240

Rep: Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324
You can also add
Code:
set -xv
as a cmd just after the comments at the top. This will show you the before & after versions of each line of code as it interprets and runs them, along with any output. Great for debugging.
 
Old 02-17-2011, 08:59 PM   #6
corp769
LQ Guru
 
Registered: Apr 2005
Posts: 5,817

Rep: Reputation: 1002Reputation: 1002Reputation: 1002Reputation: 1002Reputation: 1002Reputation: 1002Reputation: 1002Reputation: 1002
Quote:
Originally Posted by bino25 View Post
Because that's they way it was presented to me didn't know if that would matter for what the script is looking for
Oh ok, I was just wondering man. Output would be nice though, if you could try to get us some.
 
Old 02-18-2011, 08:33 AM   #7
bino25
Member
 
Registered: Dec 2010
Posts: 45

Original Poster
Rep: Reputation: 11
No errors get reported, the email just never gets sent (although the oracle says the run completed and I don't see any errors)
 
Old 02-18-2011, 10:19 AM   #8
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 17,932

Rep: Reputation: 3692Reputation: 3692Reputation: 3692Reputation: 3692Reputation: 3692Reputation: 3692Reputation: 3692Reputation: 3692Reputation: 3692Reputation: 3692Reputation: 3692
Quote:
Originally Posted by bino25 View Post
No errors get reported, the email just never gets sent (although the oracle says the run completed and I don't see any errors)
I'd check the log files (usually in /var/log), for output when you run the script manually. Look in either /var/log/messages or /var/log/mail.XX (could be mail, mail.info, or mail.warn), and see if the email message is leaving your box, and heading outwards. You'll see something obvious, look for the recipient name. If you can send to ONE email address, then chances are the other address isn't configured correctly, or that the box it's on isn't set up to accept incoming connections.

You mention the 'new' exchange alias...are you migrating from another mail system?? If so, the firewall rules/etc may not be set up right to allow incoming relays from your system. Also, make sure that the exchange server has incoming POP3/SMTP enabled. Could be it's only doing exchange-to-exchange, and is ignoring your request. Again, the logs will point that out to you, and you could see the bounce-back message there. Might also want to check /var/spool/clientmqueue (or mqueue) for received messages for the root user, or whoever you have set up to be the postmaster on that box. The rejection may be in there, too..
 
Old 02-18-2011, 05:15 PM   #9
Tinkster
Moderator
 
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 23,066
Blog Entries: 11

Rep: Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910
Quote:
Originally Posted by bino25 View Post
No errors get reported, the email just never gets sent (although the oracle says the run completed and I don't see any errors)
How is the script normally being run?

There's a lot of echo statements in there - if none show on
screen something is majorly failing all together.



Cheers,
Tink
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
mencoder script help needed mrgreaper Linux - Newbie 14 09-14-2009 01:13 PM
Script help needed! Atif_Khan Linux - Software 25 09-03-2007 01:51 AM
script help needed: patilvidya Linux - Software 2 08-29-2007 09:53 AM
Script needed ganeshinforum Programming 2 01-05-2007 08:29 AM
little script help needed abisko00 Programming 7 07-11-2005 09:37 AM


All times are GMT -5. The time now is 03:16 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration