LinuxQuestions.org
Share your knowledge at the LQ Wiki.
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 09-26-2013, 11:54 AM   #1
ptm9
LQ Newbie
 
Registered: Sep 2013
Posts: 4

Rep: Reputation: Disabled
Post uuencode in Linux


Hello,

I am relatively new to Linux but have a variety of other "UNIX" experience. I am working on an application and need to send an email attachment via mailx. In the past on "UNIX" I used uuencode to accomplish this. uuencode is not installed on any of our boxes and we are currently without a sysadmin. Are their any alternatives for uuencode in standard out-of-the-box Redhat Linux?

Thanks in advance for your help.

Pat
 
Old 09-26-2013, 01:03 PM   #2
unSpawn
Moderator
 
Registered: May 2001
Posts: 29,332
Blog Entries: 55

Rep: Reputation: 3533Reputation: 3533Reputation: 3533Reputation: 3533Reputation: 3533Reputation: 3533Reputation: 3533Reputation: 3533Reputation: 3533Reputation: 3533Reputation: 3533
Pipe the output through 'openssl base64'?
 
Old 09-26-2013, 03:57 PM   #3
Z038
Member
 
Registered: Jan 2006
Distribution: Slackware
Posts: 835

Rep: Reputation: 165Reputation: 165
uuencode is included in GNU sharutils. You can look to see if there is a redhat package for it, or you can download the source and compile.
 
Old 09-26-2013, 04:25 PM   #4
ptm9
LQ Newbie
 
Registered: Sep 2013
Posts: 4

Original Poster
Rep: Reputation: Disabled
uuencode

To: unSpawn - thank you for this. My first attempt yielded the file as the body of the message. I'll continue to work with this and try other approaches.


To: Z038 - I did find that the package exists - unfortunately, we are now "between" sysadmins, so there is nobody to install it!
 
Old 09-26-2013, 06:48 PM   #5
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Centos 6.8, Centos 5.10
Posts: 17,247

Rep: Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328
On RHEL (Centos etc), its just
Code:
yum install <pkgname>
as root user.
The yum cmd takes care of dependencies automatically & will ask for confirmation (unless the cmd name has been aliased to do otherwise).
If you like, pick the least important box and try it.
 
Old 09-26-2013, 07:06 PM   #6
unSpawn
Moderator
 
Registered: May 2001
Posts: 29,332
Blog Entries: 55

Rep: Reputation: 3533Reputation: 3533Reputation: 3533Reputation: 3533Reputation: 3533Reputation: 3533Reputation: 3533Reputation: 3533Reputation: 3533Reputation: 3533Reputation: 3533
Quote:
Originally Posted by ptm9 View Post
To: unSpawn - thank you for this. My first attempt yielded the file as the body of the message.
Most things Linux adhere to Open Standards. I suggest you re-read 'man mailx' again.
Code:
TMPFILE=`mktemp -p /tmp att.XXXXXXXXXX` && {
 cat /tmp/output_file | openssl base64 > "${TMPFILE}"
 echo "Message body" | mailx -s "Subject" -a "${TMPFILE}" user@h.ost
 rm -f "${TMPFILE}"
}
 
Old 09-26-2013, 07:50 PM   #7
ptm9
LQ Newbie
 
Registered: Sep 2013
Posts: 4

Original Poster
Rep: Reputation: Disabled
unSpawn Thanks - was relying on old practice - did need to re-read man mailx
 
Old 09-26-2013, 07:53 PM   #8
ptm9
LQ Newbie
 
Registered: Sep 2013
Posts: 4

Original Poster
Rep: Reputation: Disabled
chrism01 - thanks - it's fun here recently - no sysadmin but no one in Dev allowed to have root access for any reason
 
Old 09-27-2013, 02:01 AM   #9
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Centos 6.8, Centos 5.10
Posts: 17,247

Rep: Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328
In that case, tell the mgr some things will have to wait ...
 
  


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
uuencode question dennismonsewicz Linux - Newbie 6 01-06-2010 05:22 PM
uuencode sherimm Linux - Software 4 01-22-2009 02:47 AM
does fedora have uuencode? sorno Linux - Newbie 2 08-07-2005 07:40 AM
uuencode doesn't attach on linux bigearsbilly Programming 1 02-10-2005 09:57 AM
uuencode Berhanie Programming 4 11-27-2004 07:33 PM


All times are GMT -5. The time now is 01:04 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