Sponsored Content
Full Discussion: Linux Daytime
Operating Systems Linux Linux Daytime Post 302359350 by fpmurphy on Tuesday 6th of October 2009 10:10:40 AM
Old 10-06-2009
In redhat, the daytime service is built into xinetd. Its configuration files are in /etc/xinetd.d
i.e. daytime-dgram or daytime-stream. The RFC for the daytime protocol (RFC 867) is silent on the format of the daytime string.
Quote:
There is no specific syntax for the daytime. It is recommended that
it be limited to the ASCII printing characters, space, carriage
return, and line feed. The daytime should be just one line.
No options are provided to configure the daytime string.

However, you can configure xinetd to use an external utility as the daytime server by setting options in the configuration files. Thus you can write your own utility to output a daytime string in the format you want and configure xinetd to use this utility.

Last edited by fpmurphy; 10-06-2009 at 11:22 AM..
 

2 More Discussions You Might Find Interesting

1. Programming

why daytime don't work?

Following code is detecting solaris daytime,when I run it,I can't get any result,code is follows: #include <sys/types.h> #include <sys/socket.h> #include <netinet/in.h> #include <arpa/inet.h> #include <stdio.h> #include <stdlib.h> #include <string.h> #define BUFFSIZE 150 int main(){ ... (2 Replies)
Discussion started by: konvalo
2 Replies

2. Programming

Using Different port for Daytime Service

Hi all, is it possible to use a different port number for daytime service. By default the port number of daytime service is 13, so what if I want to get the time from a different port number e.g say 9000 (or any other port). I guess this would remain the same on the server side !... (2 Replies)
Discussion started by: manisum
2 Replies
SWITCH_ROOT(8)                                                 System Administration                                                SWITCH_ROOT(8)

NAME
switch_root - switch to another filesystem as the root of the mount tree SYNOPSIS
switch_root [-hV] switch_root newroot init [arg...] DESCRIPTION
switch_root moves already mounted /proc, /dev, /sys and /run to newroot and makes newroot the new root filesystem and starts init process. WARNING: switch_root removes recursively all files and directories on the current root filesystem. OPTIONS
-h, --help Display help text and exit. -V, --version Display version information and exit. RETURN VALUE
switch_root returns 0 on success and 1 on failure. NOTES
switch_root will fail to function if newroot is not the root of a mount. If you want to switch root into a directory that does not meet this requirement then you can first use a bind-mounting trick to turn any directory into a mount point: mount --bind $DIR $DIR SEE ALSO
chroot(2), init(8), mkinitrd(8), mount(8) AUTHORS
Peter Jones <pjones@redhat.com> Jeremy Katz <katzj@redhat.com> Karel Zak <kzak@redhat.com> AVAILABILITY
The switch_root command is part of the util-linux package and is available from https://www.kernel.org/pub/linux/utils/util-linux/. util-linux June 2009 SWITCH_ROOT(8)
All times are GMT -4. The time now is 01:30 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy