AskOverflow.Dev

AskOverflow.Dev Logo AskOverflow.Dev Logo

AskOverflow.Dev Navigation

    • 主页
    • 系统&网络
    • Ubuntu
    • Unix
    • DBA
    • Computer
    • Coding
    • LangChain

Mobile menu

Close
  • 主页
  • 系统&网络
    • 最新
    • 热门
    • 标签
  • Ubuntu
    • 最新
    • 热门
    • 标签
  • Unix
    • 最新
    • 标签
  • DBA
    • 最新
    • 标签
  • Computer
    • 最新
    • 标签
  • Coding
    • 最新
    • 标签
主页 / ubuntu / 问题

问题[coreutils](ubuntu)

Martin Hope
Alice
Asked: 2019-01-23 02:57:21 +0800 CST

核心实用程序中的多种形式的总和

  • 4

在阅读GNU Core Utilities - Wikipedia后,我发现多个总和

me@alpha:~$ cksum nohup.out 
4104911401 101860700 nohup.out
me@alpha:~$ b2sum nohup.out 
468c86394c5c4be04d0bce3b98584197b0c3f4cbb630144818f9d77d48ab7296e4c53db481b6bdd7c46dd5203d3f016d9ef01b126806e04be5003aeebb1bc6
22  nohup.out                                                                                                                
me@alpha:~$ sum nohup.out 
37767 99474
me@alpha:~$ sha1sum nohup.out 
79106925d593e18bd148ba94a6e4fb9da02e8c47  nohup.out
 me@alpha:~$ md5sum nohup.out 
3be4b17f18e4715d849a31ae482565cf  nohup.out

我几个月前开始学习linux,我是否必须区分它们并在日常操作中使用它们?

coreutils
  • 2 个回答
  • 259 Views
Martin Hope
Alice
Asked: 2019-01-23 00:13:22 +0800 CST

消息返回'是 y'

  • 0

发出“消息”后

me@alpha:~$ mesg
 is y

手册指出

NAME
       mesg - display (or do not display) messages from other users

这是否意味着有人入侵了我的机器并留言?

coreutils
  • 2 个回答
  • 112 Views
Martin Hope
ghost
Asked: 2018-12-16 19:27:36 +0800 CST

cut 的 -b 和 -c 选项有什么区别?

  • 0

我在网上搜索了示例,浏览了该cut命令的参考手册并自己进行了测试,但仍不确定该-b标志。没有任何关于该cut -b命令如何工作的明确示例。有人可以创建一个示例文件并展示它是如何清晰使用的吗?

command-line coreutils
  • 1 个回答
  • 2552 Views
Martin Hope
fixit7
Asked: 2018-08-12 10:27:40 +0800 CST

使用 sleep 与分钟和秒

  • 16

我知道如何使用 sleep 5m for 5 分钟。

我将如何使用它说 7 分 30 秒?

command-line coreutils
  • 4 个回答
  • 5075 Views
Martin Hope
Gowtham
Asked: 2018-08-11 05:04:13 +0800 CST

如何更改默认日期格式(使用 LC_TIME)?

  • 2

如何通过在语言环境中date进行修改来更改命令格式LC_TIME?

目前,月份中的日期使用%e格式。我需要它以%d格式显示。

以下是当前格式:

#date
Thu Aug 9 18:26:11 IST 2018

预期格式:

#date
Thu Aug 09 18:26:11 IST 2018

这是我的语言环境:

#locale
LANG=en_US.UTF-8
LANGUAGE=
LC_CTYPE=en_IN
LC_NUMERIC="en_US.UTF-8"
LC_TIME="en_US.UTF-8"
LC_COLLATE="en_US.UTF-8"
LC_MONETARY="en_US.UTF-8"
LC_MESSAGES="en_US.UTF-8"
LC_PAPER="en_US.UTF-8"
LC_NAME="en_US.UTF-8"
LC_ADDRESS="en_US.UTF-8"
LC_TELEPHONE="en_US.UTF-8"
LC_MEASUREMENT="en_US.UTF-8"
LC_IDENTIFICATION="en_US.UTF-8"
LC_ALL=

LC_TIME中的部分/usr/share/i18n/locales/en_US:

    LC_TIME
abday   "Sun";"Mon";"Tue";"Wed";"Thu";"Fri";"Sat"
day "Sunday";/
    "Monday";/
    "Tuesday";/
    "Wednesday";/
    "Thursday";/
    "Friday";/
    "Saturday"

week 7;19971130;1
abmon   "Jan";"Feb";/
    "Mar";"Apr";/
    "May";"Jun";/
    "Jul";"Aug";/
    "Sep";"Oct";/
    "Nov";"Dec"
mon "January";/
    "February";/
    "March";/
    "April";/
    "May";/
    "June";/
    "July";/
    "August";/
    "September";/
    "October";/
    "November";/
    "December"
% Appropriate date and time representation (%c)
d_t_fmt "%a %d %b %Y %r %Z"
%
% Appropriate date representation (%x)
d_fmt   "%m//%d//%Y"
%
% Appropriate time representation (%X)
t_fmt   "%r"
%
% Appropriate AM/PM time representation (%r)
t_fmt_ampm "%I:%M:%S %p"
%
% Strings for AM/PM
%
am_pm   "AM";"PM"
date_fmt "%F %Z"
END LC_TIME

请让我知道我可以做些什么来获得预期的格式。

注意:我只需要执行date没有任何格式化选项的命令。

command-line locale coreutils date
  • 1 个回答
  • 12107 Views
Martin Hope
Antonio
Asked: 2018-06-01 03:59:42 +0800 CST

不同版本的 `sync` 工具

  • 0

关于该工具有两个man页面:sync

(1) http://man7.org/linux/man-pages/man1/sync.1.html

NAME         

       sync - Synchronize cached writes to persistent storage

SYNOPSIS         top

       sync [OPTION] [FILE]...

DESCRIPTION         top

       Synchronize cached writes to persistent storage

       If one or more files are specified, sync only them, or their
       containing file systems.

       -d, --data
              sync only file data, no unneeded metadata

       -f, --file-system
              sync the file systems that contain the files

       --help display this help and exit

       --version
              output version information and exit

(2) http://manpages.ubuntu.com/manpages/trusty/en/man8/sync.8.html

NAME
       sync - synchronize data on disk with memory

SYNOPSIS
       sync [--help] [--version]

DESCRIPTION
       sync  writes any data buffered in memory out to disk.  This can include
       (but is not limited to)  modified  superblocks,  modified  inodes,  and
       delayed  reads and writes.  This must be implemented by the kernel; The
       sync program does nothing but exercise the sync(2) system call.

       The kernel keeps data in memory to avoid doing (relatively  slow)  disk
       reads  and  writes.   This  improves  performance,  but if the computer
       crashes, data may be lost or the  filesystem  corrupted  as  a  result.
       sync ensures that everything in memory is written to disk.

       sync  should  be  called  before  the processor is halted in an unusual
       manner (e.g., before causing a kernel panic when debugging  new  kernel
       code).    In   general,  the  processor  should  be  halted  using  the
       shutdown(8) or reboot(8) or halt(8) commands, which will attempt to put
       the  system  in  a  quiescent  state  before calling sync(2).  (Various
       implementations of these commands exist; consult your documentation; on
       some systems one should not call reboot(8) and halt(8) directly.)

第一个来自coreutils,第二个来自fileutils。我尝试sync从 Ubuntu 14.04 中编译该工具,coreutils 8.29但得到的结果与sync(2) 相同。

如何sync在 Ubuntu 14.04 上获得具有功能 (1) 的工具?

filesystem sync coreutils
  • 1 个回答
  • 72 Views
Martin Hope
Olivier Lalonde
Asked: 2010-12-14 20:48:30 +0800 CST

cp复制文件时如何显示传输进度和速度?

  • 522

否则,是否有任何替代命令行实用程序可以实现此目的?

command-line coreutils
  • 24 个回答
  • 886266 Views

Sidebar

Stats

  • 问题 205573
  • 回答 270741
  • 最佳答案 135370
  • 用户 68524
  • 热门
  • 回答
  • Marko Smith

    如何运行 .sh 脚本?

    • 16 个回答
  • Marko Smith

    如何安装 .tar.gz(或 .tar.bz2)文件?

    • 14 个回答
  • Marko Smith

    如何列出所有已安装的软件包

    • 24 个回答
  • Marko Smith

    无法锁定管理目录 (/var/lib/dpkg/) 是另一个进程在使用它吗?

    • 25 个回答
  • Martin Hope
    Flimm 如何在没有 sudo 的情况下使用 docker? 2014-06-07 00:17:43 +0800 CST
  • Martin Hope
    Ivan 如何列出所有已安装的软件包 2010-12-17 18:08:49 +0800 CST
  • Martin Hope
    La Ode Adam Saputra 无法锁定管理目录 (/var/lib/dpkg/) 是另一个进程在使用它吗? 2010-11-30 18:12:48 +0800 CST
  • Martin Hope
    David Barry 如何从命令行确定目录(文件夹)的总大小? 2010-08-06 10:20:23 +0800 CST
  • Martin Hope
    jfoucher “以下软件包已被保留:”为什么以及如何解决? 2010-08-01 13:59:22 +0800 CST
  • Martin Hope
    David Ashford 如何删除 PPA? 2010-07-30 01:09:42 +0800 CST

热门标签

10.10 10.04 gnome networking server command-line package-management software-recommendation sound xorg

Explore

  • 主页
  • 问题
    • 最新
    • 热门
  • 标签
  • 帮助
subwaysurfers
my femboy roommate

Footer

AskOverflow.Dev

关于我们

  • 关于我们
  • 联系我们

Legal Stuff

  • Privacy Policy

Language

  • Pt
  • Server
  • Unix

© 2023 AskOverflow.DEV All Rights Reserve