Sendmail using sendmail of Linux

could someone help me with the problem:
I need to send mails using sendmail of linux(I cannot user JavaMail API) using Java.
Thanks in advance.
Suman

Hi, I can't find anything about sending email using java classes on the referd www. adress. Is it possible that you post some code about using /usr/sbin/sendmail on the server? Tnx

Similar Messages

  • Sending mail in java using sendmail programme of lynix

    Hi,
    How can I send mail using Java and lynux "sendmail" programme located at i.e sendmail: /usr/sbin/sendmail.
    I don't want to use JavaMail API for sending. I want to use sendmail of lynix server. Plz help me. It's very uregent.
    Regards,
    Devom

    Hey Guys, here is the workaround for sending mails in java through javamail program of linux/unix:
    step 1 - Create a shell script which sends the mail using the 'sendmail' program. I have written below code in my shell script:
    #!/bin/sh
    #script to send simple email
    # email subject
    SUBJECT="Test Subject"
    # Email To ?
    EMAIL="[email protected],[email protected]"
    # Email text/message. This file will be automatically created and all text will be appended in it.
    EMAILMESSAGE="/tmp/emailmessage.txt"
    echo "This is a sample mai text."> $EMAILMESSAGE
    echo "And this is a also." >>$EMAILMESSAGE
    echo " " >>$EMAILMESSAGE
    echo " " >>$EMAILMESSAGE
    echo "Thanks & Regards," >>$EMAILMESSAGE
    echo "--Your Name" >>$EMAILMESSAGE
    mail -s "$SUBJECT" "$EMAIL" < $EMAILMESSAGE
    So create this script and save it as 'sendmail.sh' name in the same directory where you are executing your main java class. Please also note that this file should have full executable permissions for the program which is using this file.
    Step 2- Here is my Java code that executed this shell script:
    public void sendEmail()
    String operatingSystemProp = "os.name";
    String operatingSystemName = System.getProperty(operatingSystemProp);
    if(!operatingSystemName.startsWith("Windows"))
    String cmd = "./sendmail.sh";//unix shell script
    try
         Runtime.getRuntime().exec(cmd);
    }catch (Exception e)
         e.printStackTrace();
    You just need to call this method in your java code. This method will actually pick that shell script in runtime and will execute it, the rest will be handled by the shell script itself.
    So this workaround works fine for me and now I am sending mails through my java program using sendmail.
    Cheers!

  • How to send multiple documents using SENDMAIL step

    Hi Experts,
                         I have  a requirement to send a notification to multiple users using SENDMAIL step. How can I do this? I thought to create a method in the BO and to export ACTOR_TAB to wrkflow but the problem is I am unable to create an export parameter in the method with the type SWHACTOR.
    Can anybody please suggest me hw to trigger sendmail to multiple persons.
    Regards.
    Ranganadh

    Hi Smit,
                      I am facing another problem actually I tried above solution by givin initial values in the workflow container. But now in my implementation program when I am populating the event container with SWC_SET_TABLE its giving me dump by saying type conflict.
    Is it possible to use SWC_SET_TABLE command in SE38 programs?
    Please suggest me how to populate the event container in report programs. I have included <CNTN01> in my report.
    Thank you.
    Ranganadh

  • Sending mails without using sendmail service. Is that possible?

    Hi all,
    I am considerably new to Solaris.
    I have a query,
    Is it possible to send mails out without using sendmail service?
    If so how can they be implemented in,
    Solaris 7?
    Solaris 8?
    Solaris 9?
    If it is not possible, are there any workarounds to achieve this or else this cannot be implemented at all?
    It would be really great if someone could shed light on this query.

    Your question is a little ambiguous. However, I will try to answer it.
    You need to use a program to send the email for you. On Solaris by default this is sendmail. However, it can be used in a number of modes.
    1. It can be run as a daemon, listening on port 25 for new messages to be delivered to it.
    This is enabled by default but is not necessary for sending email. If you wish to switch sendmail off as a service in Solaris10 then you should type 'svcadm disable svc:/network/smtp:sendmail'. If you wish to switch it off on earlier Solaris releases you will need to move/erase the startup script in either /etc/rc2.d or /etc/rc3.d.
    2. It can be run in 'immediate mode' to send mail immediately.
    This allows you to send a mail directly to someone. On a normally configured sendmail instance it will try to deliver the mail immediately - if the server at the other end is unavailable, the mail will be queued locally to be potentially delivered at a later date.
    3. It can run in delivery only mode to attempt to send queued mail
    Queued mail will not automatically get processed. Sendmail needs to run at a later date to attempt to deliver any queued mail. This can either be done via cron using 'sendmail -q' or sendmail can be left running the whole time and told to rerun the queue in given periods ie 'sendmail -q15m'
    There are alternatives to sendmail for delivering mail - postfix, exim, qmail are just three examples. I would advise against trying to deliver mail without using a specific mail agent to do it. Whilst the SMTP mail protocol is pretty simple in basic use cases the protocol does get complex. There is no real downside in using an established program.
    HTH.

  • SendMail using JSP

    I am using sendMail.jsp which developed for 91AS.
    In this application there is a method called
    sendMail.setRecipient(to);
    the parameter is string. I am using this method inside a loop where the string is iterated and has values seperated by commas.However in the method the string has only the last value which I populate and when I print the string it has all the values?
    Is there any restriction in the sendmail method?
    Any help is appreciated.

    Check out jMailComposer. It supports multilanguages.
    http://www.javazoom.net/jzservlets/jmailcomposer/jmailcomposer.html

  • Using Sendmail from a Virtual Host

    I'm testing some Perl CGI scripts which use sendmail to send out emails. These scripts are used by different organisations and I've set up a virtual host for each organisation. I'm finding that the script communicates with sendmail OK but the messages are not getting through and I see from the error log at /var/mail/ that these are being rejected with part of the error message being:
    "Final-Recipient: rfc822; *****@mac.com
    Action: failed
    Status: 5.1.1
    Remote-MTA: dns; smtp-mx1.mac.com
    Diagnostic-Code: smtp; 550 5.1.1 unknown or illegal alias: *****@mac.com"
    --183FD34686D.1210867525/EricMac.local
    Content-Description: Undelivered Message
    Content-Type: message/rfc822"
    What do I need to do to correct this?
    <Edited by Moderator>

    You'll see from my other posting that my problems with sendmail have been solved. I seem to be doing the same as you - testing Perl scripts on the Mac before uploading to the live server. I'm doing this with scripts for different clients and I've set up virtual hosts for each on the Mac, and I'm using ActiveState's IDE, Komodo, to do the testing.
    When I had my initial problems with sendmail I was told that I had to configure it. However I'm not using the Apache that comes with my MacBook Pro. I downloaded MAMP PRO from http://www.mamp.info/en/mamp-pro/ which provides Apache, MySQL and PHP already configured for the Mac and also allows virtual hosts to be set up easily - there is also a free version MAMP that provides these three but not the frills.
    It seems that sendmail is already configured in MAMP, at least I haven't done any configuration, and this might be your answer if you're still having problems with sendmail

  • Configure Sendmail using POP/IMAP

    Hello !
    I need some consise and comprehensive help/tutorial or material/reference of any sort, as to how to configure Mail service using Sendmail and POP/IMAP service.
    I would be highly obliged!

    I take it that you want to get personal email while at work which may or may not be okay with your company policy - but that's for you to decide.
    A way around it.
    I use Oceanic Time Warner RoadRunner as an ISP and it has an option that allows me to access and send email when I am on the road called Web Mail that is accessed from my browser home page (RoadRunner). Mail won't allow you to access your normal mail except for viewing not sending messages when you're not in your local area, so Web Mail takes the place of using Mail. I access it through http.
    Your email provider should have something similar with a web address as long as you can access it through your computer at work.

  • Using Sendmail through Java

    Hello,
    How do you use the sendmail program from java. Are there any classes to do this. I can't use JavaMail because my ISP does not give me an SMTP server to use. They told me that I can use the sendmail program, but I don't know how to not only execute this program, but also to pass the necessary parameters to it.
    Thanks

    It seems to me in order to use a mail server (sendmail) it has to have a verifiable ip address are you on a desk top?
    If you are the only way is to configure sendmail to emulate or (masquarade as another verifiable server)
    probubly your ISP but that is not easy and or possibly not ethical.
    This is tough this way so strangers and weirdos can't flood the mail system with untraceable mail.
    You may find free smtp server access on the net somewhere.
    I think using sendmail with java.mail package or any java mail package is the same as comunicating with any mail server only now with a local address I could be off on that as well.

  • Any issues with using LDAP on LINUX for GRC 5.2 UME?

    Our company is converting our LDAP servers from AIX to LINUX.  The DNS name used in our UME connection should not change.  Are there any issues with using LDAP on LINUX?  We are currently on GRC 5.2 SP9 (in the middle of upgrading to SP12).
    Also, I have been trying to connect our test UME system to a test LDAP box that has already been converted to LINUX but keep getting a 'connection failed' error when I try to test it. 
    Do you have to reboot the server to test changing the LDAP connections?  I've been trying it by going into UME, pulling up the LDAP tab, hitting the Modify button, entering the new userid and password for test LDAP, and hitting the Test Connection button.  I've verified that this userid and password is correct for test LDAP.
    Is there a way to get more information about why the connection failed?
    Thanks.

    I've been told by our LDAP Support group that none of the other configuration settings should have to be changed.  I should only have to change the id and password to connect to a test version of LDAP instead of our regular connection to the production LDAP.
    Can you test a connection for a different userid/password without having to reboot/restart the server?  Do I need to change these two settings, save then, reboot/restart, and then do the Test Connection button?
    Thanks.

  • How to run SAP BUSINESS ONE 8.8 clients on windows and use MaxDB on linux/W

    Good day,
    As the subject shows we have SAP BUSINESS ONE 8.8 and I want to find out how to use it in combination with MaxDB instead of MS SQL. I find a lot of MaxDB stuff on the net but no guides on how to setup SAP BUSINESS ONE 8.8 clients on windows workstations and connect them to MaxDB.
    Is this possible and if so how do I go about doing it ?
    Any assistance is greatly appreciated .

    Hi,
    I suggest you to check the supported server for B1 in this link:
    http://service.sap.com/smb/sbo/platforms
    You will know the sap b1 supported platform.
    If you really want to use maxDB on linux/W as B1 server, you can send a development request to SAP AG.
    JimM

  • How do I combine multiple PDF using PHP on Linux

    Hi,
    I would like to know if there is an Adobe product that can combine multiple PDF's into a single document and works on Linux? We are developing an application using PHP on Linux that has to combine selected PDF's and would like to know if there is a tool with api's (or command line interface) to allow that.

    Adobe licenses the PDF Library SDK for native developers on Linux platforms (as C code). They do not supply PHP tools.

  • Trying to use 10G for linux

    Two Problems
    1. I downloaded 10 for linux,
    used gunzip
    Now I am at ship.db.cpio
    I ran cpio -idmv ship.db.cpio
    The command never stoped, what did I do wrong ???
    Next problem
    The 10G for linux state:
    I need to change on my linux computer,
    sysctl.conf, pam.d/login, limits.conf, profile
    There all read only files,
    What do I need to do ????
    I am using Red hat linux EP. rev 3 newest one.

    1. Use cpio -idmv <ship.db.cpio
    sysctl.conf, pam.d/login, limits.conf, profileThese are system files : you have to login as root to modify them, or su - root if you are already connected as another user.

  • Need list of indian s/w companies using Oracle on Linux

    Hi,
    I am in need of the list of companies in India who use Oracle on Linux, if any one has such an list then please do send it to me at [email protected]
    I am exploring the companies names ,so that I can apply for the post of 'Oracle DBA' on LINUX platform,thus if i could obtain such a list then my job hunt will become much easier.
    So,if any one has got such info then please do pass it on to me .
    Krishna k.
    09819152725

    It's been discussed before,
    Re: Want to use SGA=3gb+  in  RHEL 4.3 (32bit)
    There's some work around with performance penalty

  • Using CF8 on Linux

    Ok, I'm new to using CF on Linux, so here's my question.
    On Windows you have to tell CF what sites you want the CF
    server to serve up
    pages for. Is there a similar way to do this in Linux?
    I installed CF on Fedora, and can get to the CF admin page
    via Firefox just
    fine. When I try to view a webpage on
    http://localhost/page.cfm it
    displays
    the page, but the CF tags aren't being translated, they show
    up as text on
    the page.....

    Steve,
    How are you getting to CFAdmin? Does your URL include port
    8500 or similar? If so, the administrator is working thru
    coldfusion's internal webserver (JWS). I suspect that is what is
    going on.
    If that is the case, review the installation guide for
    configuring webservers. You will have several options to get CF
    connected to apache or whatever webserver you are running. Also,
    details like CF version, webserver type, etc. are useful when you
    post.

  • Dataload error using MaxL on LINUX

    Hi All,
    I'm using Essbase 11.1.2.1 & working on ASO cube. I'm trying to load the data using Maxl on LINUX.
    This is the following error: essmsh error: End of File breaks the Statement.
    any ideas.......
    Thanks,

    rasch wrote:
    Hi,
    I am using DAQmx-base (C library) on Linux with a USB-6009 device. When I am acquiring data
    using DAQmxBaseReadAnalogF64() (the code is based on the example contAcquireNChan.c)
    everything works, but when I am using DAQmxBaseReadBinaryI16() the following error
    happens:
    DAQmxBase Error: Value passed to the Task/Channels In control is invalid.
    Everything is the same just the ...AnalogF64 is replaced by the ...BinaryI16 function call
    (of course the buffer used for storing the data was also changed from float64 to in16).
    Does anyone know what settings (or missing settings) result in this error?
    Every explanation or pointer to some documentation is welcome. I already checked the
    C reference HTML documentation coming with DAQmx-base without success.
    Thanks
    Raphael
    From the ReadMe file for DAQmx Base on Macintosh OS X:
    NI USB-9211
    *Analog Input
    -Multi-channel, multi-sample read (scaled)
    -Multi-channel, single sample read (scaled)
    NI USB-9215
    *Analog Input
    -Multi-channel, multi-sample read (scaled)
    -Multi-channel, single sample read (scaled)
    NI USB-6008/9
    *Analog Input
    -Digital start triggering
    -Multi-channel, multi-sample read (scaled)
    -Multi-channel, single sample read (scaled)
    Raw input simply isn't supported for the USB devices. I would guess that the situation for Linux is the same, since DAQmx Base is based on Labview code in order to achieve cross-platform portability. See the thread
    http://forums.ni.com/ni/board/message?board.id=250&message.id=11873
    and, for a slightly different problem:
    http://forums.ni.com/ni/board/message?board.id=250&message.id=11963
    Be sure to read down to where there is a message indicating that support for USB devices is planned for NI-DAQmx. Of course, that won't help on Macintosh and Linux.
    John Weeks
    WaveMetrics, Inc.
    Phone (503) 620-3001
    Fax (503) 620-6754
    www.wavemetrics.com

Maybe you are looking for

  • How do I fix error 13019 with my ipod nano?

    Yes, I've been looking online. I've read the support article, and it doesn't apply to my question. No, I don't sync my music automatically. None of those tabs are checked. I don't have any voice memos, either. This error happens when I plug in my ipo

  • How to get start with CryptoAPI?

    I am new in Microsoft CryptoAPI so I want to know the tools, some code examples and learning materials ?

  • Totals in BEx query not matching with actual total

    Hi, We have one report in BI, the total for few columns (Given by BI system i.e system generated) for the values of the key figures is not matching with actual total of that values... I am confused to see, how sap BI can do the totaling mistake... Pl

  • Trouble with remote file sharing

    Hi, I'm trying to set up an iMac here in my office so that it can be used for remote file sharing. I'm kinda new at this, so I'm sure I've missed a few obvious details. First off, it's connected via AirPort and there's no direct ethernet connection..

  • JTable loses cell renderers

    Well I just had an annoying bug that took me a long time to diagnose. Under certain circumstances, my JTable would suddenly redraw using all default cell renderers - my overriding renderers just stopped being used. Until today I was not able to repro