HPE GreenLake Administration
- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- how to specify from@ with ELM
Operating System - HP-UX
        1839432
        Members
    
    
        3041
        Online
    
    
        110146
        Solutions
    
Forums
        Categories
Company
Local Language
                
                  
                  back
                
        
                
        
                
        
                
        
        
        
                
        
                
        
        
        
                
        
              
              Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
                
                  
                  back
                
            
                
            
                
            
                
            
                
            
                
            
                
            
                
            
                
            
                
            
                
            
                
            
                
            
                
            
                
            
                
            
                
            
            
                
            
                
            
                
            
                
            
            
                
            
                
            
            
                
            
                
              
            Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Blogs
        Information
        Community
Resources
Community Language
        Language
        Forums
Blogs
Topic Options
			
				
					
	
			
		
	- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-14-2003 12:19 PM
08-14-2003 12:19 PM
			
				
					
						
							how to specify from@ with ELM
						
					
					
				
			
		
	
			
	
	
	
	
	
			
				
					
					
						Hi,
I'm using the following command to send email with attachment:
elm -s "$SUBJECT" -a $MAILTO < body
(body contain [include file1 text/play base64])
by default reciepient have user email address that runs this shell and I need to change it to predefined $MAILFROM. Moreover it will run in production thru cron (i.e. without user involvment). Couldn't find any similar options in man elm.
Anybody has a solution ?
Thanks to all.
		
		
	
	
	
I'm using the following command to send email with attachment:
elm -s "$SUBJECT" -a $MAILTO < body
(body contain [include file1 text/play base64])
by default reciepient have user email address that runs this shell and I need to change it to predefined $MAILFROM. Moreover it will run in production thru cron (i.e. without user involvment). Couldn't find any similar options in man elm.
Anybody has a solution ?
Thanks to all.
	beer or not beer
			
			
				
			
			
			
			
			
			
		
		3 REPLIES 3
	
	            
            
		
		
			
            
                - Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-16-2003 12:11 AM
08-16-2003 12:11 AM
			
				
					
						
							Re: how to specify from@ with ELM
						
					
					
				
			
		
	
			
	
	
	
	
	
			
				
					
					
						generally while sending mails in a script mailx command is used.
man mailx will be able to help you.
		
		
	
	
	
man mailx will be able to help you.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-16-2003 08:49 PM
08-16-2003 08:49 PM
			
				
					
						
							Re: how to specify from@ with ELM
						
					
					
				
			
		
	
			
	
	
	
	
	
			
				
					
					
						From the elm man page:
A file, $HOME/.elm/elmrc, that defines the initial values for elm configuration variables.
So you can setup the $MAILFROM there for the login ID for the crontab in question. Or, you can use "su" to switch to the appropriate use to send the mail. You can do this with the -c option which will allow the crontab ID to run the process to create the attachment (which I assume is the case), and then switch just to send the e-mail:
eval "su - [userID] -c "[elm $SUBJECT -a $MAILTO
mark
		
		
	
	
	
A file, $HOME/.elm/elmrc, that defines the initial values for elm configuration variables.
So you can setup the $MAILFROM there for the login ID for the crontab in question. Or, you can use "su" to switch to the appropriate use to send the mail. You can do this with the -c option which will allow the crontab ID to run the process to create the attachment (which I assume is the case), and then switch just to send the e-mail:
eval "su - [userID] -c "[elm $SUBJECT -a $MAILTO
mark
	the future will be a lot like now, only later
			
			
				
			
			
			
			
			
			
		- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-17-2003 01:32 PM
08-17-2003 01:32 PM
			
				
					
						
							Re: how to specify from@ with ELM
						
					
					
				
			
		
	
			
	
	
	
	
	
			
				
					
					
						Even if you were able to set the sender address through Elm, sendmail may clobber it anyway unless the invoking user is trusted (add the username to /etc/mail/trusted-users or another Tuser line in sendmail.cf).
If you want this to be permanent, you may also consider using the genericstable feature in sendmail to always mask a user with whatever e-mail address you want. Are you familiar with this feature?
					
				
			
			
				
			
			
				
			
			
			
			
			
			
		
		
		
	
	
	
If you want this to be permanent, you may also consider using the genericstable feature in sendmail to always mask a user with whatever e-mail address you want. Are you familiar with this feature?
The opinions expressed above are the personal opinions of the authors, not of Hewlett Packard Enterprise. By using this site, you accept the Terms of Use and Rules of Participation.
		
	
	
Company
Events and news
Customer resources
© Copyright 2025 Hewlett Packard Enterprise Development LP
