01-08-2002
The permissions on the file were correct before you changed them (if you are running Solaris).
As far as getting nothing into the file, check the ownership. Make sure you are root when you edit the file. If you can't seem to edit the file, then you can always copy contents of one file to it (cp ./mynew.motd /etc/motd ) as root. Insure you check that the permissions are correct afterwards.
10 More Discussions You Might Find Interesting
1. UNIX for Advanced & Expert Users
Anyone know how to change the location of the MOTD file from the default /etc/motd?
An annoying person with root access has found out how to edit the file and change my MOTDs.
Help me. (14 Replies)
Discussion started by: Rex00me
14 Replies
2. UNIX for Advanced & Expert Users
Hi,
I was hoping to get some help on this question:
I have different groups of users logging into our servers and I would like to set it up so that when they login they could get an update from the motd.
How do I set it up so that I can have one group see a different motd than the system... (1 Reply)
Discussion started by: vancouver_joe
1 Replies
3. UNIX for Dummies Questions & Answers
Hie guys
im new to Unix. Need some advise or favour perhaps. Iam running Red hat Linux 7.2 and as soon as i install with GUI and so done, i reboot the system. After i reboot it directly went to the GUI login. I able to login and do my stuffs. My question is how to hold the system not to directly... (4 Replies)
Discussion started by: ###1tomato
4 Replies
4. Shell Programming and Scripting
I need to replace the current /etc/motd text file with a new motd across 30+ servers.
Which is the best way to do this? Shell script? sed?
Does anyone have an example I can use?
Thanks in advance. Unix people are the best!!! :) (2 Replies)
Discussion started by: antalexi
2 Replies
5. UNIX for Dummies Questions & Answers
Hi
I do get the message of the day upon logging in to my machine(Solaris 9). I do NOT have a .hushlogin file in my home directory.
Any ideas
:-) (7 Replies)
Discussion started by: run_time_error
7 Replies
6. UNIX for Dummies Questions & Answers
Does anyone know how to get the IP Address of the connecting client to apear in the MOTD I am new to linux and I was wondering if this was possible thanks in advance. :D :confused: :D (4 Replies)
Discussion started by: DragonLenage
4 Replies
7. Linux
In which login startup script is the motd displayed?
Red Hat 4AS
As I understand it, upon login (bash) it hits
/etc/profile
~/.bash_profile
~/.bash_login
~/.profile
I went through the scripts and the associated scripts (/etc/profile.d/*.sh) but don't see where it's being displayed... (5 Replies)
Discussion started by: BOFH
5 Replies
8. Solaris
Hi all,
Wish to check which setting is set to display the MOTD AFTER successful password verification. I am logging in via a 3rd party ssh tool tectia.
Eg.
Login:
password:
OS Prompt>
Thanks
Eugene (5 Replies)
Discussion started by: srage
5 Replies
9. Linux
Hi,
I am using Ubuntu 10.04 desktop and whenever I login to the xterm terminal through ssh, I am getting the following motd (message of the day) info.
Linux desktop 2.6.32-28-generic #55-Ubuntu SMP Mon Jan 10 21:21:01 UTC 2011 i686 GNU/Linux
Ubuntu 10.04.2 LTS
Welcome to Ubuntu!
*... (1 Reply)
Discussion started by: royalibrahim
1 Replies
10. UNIX for Dummies Questions & Answers
Hello,
which is the default motd for the different following different OS versions?
RHEL: has no default motd?
HP-UX: no motd but cat /etc/copyright in /etc/profile:
(c)Copyright 1983-2003 Hewlett-Packard Development Company, L.P.
(c)Copyright 1979, 1980, 1983, 1985-1993 The Regents of the... (2 Replies)
Discussion started by: asanchez
2 Replies
LEARN ABOUT PHP
stream_socket_enable_crypto
STREAM_SOCKET_ENABLE_CRYPTO(3) 1 STREAM_SOCKET_ENABLE_CRYPTO(3)
stream_socket_enable_crypto - Turns encryption on/off on an already connected socket
SYNOPSIS
mixed stream_socket_enable_crypto (resource $stream, bool $enable, [int $crypto_type], [resource $session_stream])
DESCRIPTION
Enable or disable encryption on the stream.
Once the crypto settings are established, cryptography can be turned on and off dynamically by passing TRUE or FALSE in the $enable param-
eter.
PARAMETERS
o $stream
- The stream resource.
o $enable
- Enable/disable cryptography on the stream.
o $crypto_type
- Setup encryption on the stream. Valid methods are
o STREAM_CRYPTO_METHOD_SSLv2_CLIENT
o STREAM_CRYPTO_METHOD_SSLv3_CLIENT
o STREAM_CRYPTO_METHOD_SSLv23_CLIENT
o STREAM_CRYPTO_METHOD_TLS_CLIENT
o STREAM_CRYPTO_METHOD_SSLv2_SERVER
o STREAM_CRYPTO_METHOD_SSLv3_SERVER
o STREAM_CRYPTO_METHOD_SSLv23_SERVER
o STREAM_CRYPTO_METHOD_TLS_SERVER
If omitted, the $crypto_type context option on the stream's SSL context will be used instead.
o $session_stream
- Seed the stream with settings from $session_stream.
RETURN VALUES
Returns TRUE on success, FALSE if negotiation has failed or 0 if there isn't enough data and you should try again (only for non-blocking
sockets).
CHANGELOG
+--------+------------------------------------+
|Version | |
| | |
| | Description |
| | |
+--------+------------------------------------+
| 5.6.0 | |
| | |
| | The $crypto_type is now optional. |
| | |
+--------+------------------------------------+
EXAMPLES
Example #1
stream_socket_enable_crypto(3) example
<?php
$fp = stream_socket_client("tcp://myproto.example.com:31337", $errno, $errstr, 30);
if (!$fp) {
die("Unable to connect: $errstr ($errno)");
}
/* Turn on encryption for login phase */
stream_socket_enable_crypto($fp, true, STREAM_CRYPTO_METHOD_SSLv23_CLIENT);
fwrite($fp, "USER god
");
fwrite($fp, "PASS secret
");
/* Turn off encryption for the rest */
stream_socket_enable_crypto($fp, false);
while ($motd = fgets($fp)) {
echo $motd;
}
fclose($fp);
?>
The above example will output something similar to:
SEE ALSO
"OpenSSL Functions", "List of Supported Socket Transports".
PHP Documentation Group STREAM_SOCKET_ENABLE_CRYPTO(3)