{
    "mode": "man",
    "parameter": "LOGSAVE",
    "section": "8",
    "url": "https://www.chedong.com/phpMan.php/man/LOGSAVE/8/json",
    "generated": "2026-05-30T09:07:34Z",
    "synopsis": "logsave [ -asv ] logfile cmdprog [ ... ]",
    "sections": {
        "NAME": {
            "content": "logsave - save the output of a command in a logfile\n",
            "subsections": []
        },
        "SYNOPSIS": {
            "content": "logsave [ -asv ] logfile cmdprog [ ... ]\n",
            "subsections": []
        },
        "DESCRIPTION": {
            "content": "The  logsave program will execute cmdprog with the specified argument(s), and save a copy of\nits output to logfile.  If the containing directory for logfile does not exist, logsave  will\naccumulate  the output in memory until it can be written out.  A copy of the output will also\nbe written to standard output.\n\nIf cmdprog is a single hyphen ('-'), then instead of executing a program, logsave will  take\nits input from standard input and save it in logfile\n\nlogsave  is  useful for saving the output of initial boot scripts until the /var partition is\nmounted, so the output can be written to /var/log.\n",
            "subsections": []
        },
        "OPTIONS": {
            "content": "",
            "subsections": [
                {
                    "name": "-a",
                    "content": "current contents.\n",
                    "flag": "-a"
                },
                {
                    "name": "-s",
                    "content": "with a control-A (ASCII 001 or Start of Header) and control-B (ASCII 002 or  Start  of\nText).  This allows progress bar information to be visible to the user on the console,\nwhile not being written to the log file.\n",
                    "flag": "-s"
                },
                {
                    "name": "-v",
                    "content": "",
                    "flag": "-v"
                }
            ]
        },
        "AUTHOR": {
            "content": "Theodore Ts'o (tytso@mit.edu)\n",
            "subsections": []
        },
        "SEE ALSO": {
            "content": "fsck(8)\n\n\n\nE2fsprogs version 1.46.5                    December 2021                                 LOGSAVE(8)",
            "subsections": []
        }
    },
    "summary": "logsave - save the output of a command in a logfile",
    "flags": [
        {
            "flag": "-a",
            "long": null,
            "arg": null,
            "description": "current contents."
        },
        {
            "flag": "-s",
            "long": null,
            "arg": null,
            "description": "with a control-A (ASCII 001 or Start of Header) and control-B (ASCII 002 or Start of Text). This allows progress bar information to be visible to the user on the console, while not being written to the log file."
        },
        {
            "flag": "-v",
            "long": null,
            "arg": null,
            "description": ""
        }
    ],
    "examples": [],
    "see_also": [
        {
            "name": "fsck",
            "section": "8",
            "url": "https://www.chedong.com/phpMan.php/man/fsck/8/json"
        }
    ]
}