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
    • 最新
    • 标签
主页 / user-608146

Toodarday's questions

Martin Hope
Toodarday
Asked: 2021-01-22 11:40:48 +0800 CST

如何将 netstat 输出转换为变量

  • 1
netstat -an | grep :443 | grep -v TIME_WAIT | wc -l

如何将此返回值 171 转换为变量foo,以便如果我输入$foo它将返回 171。

bash
  • 1 个回答
  • 298 Views
Martin Hope
Toodarday
Asked: 2020-06-02 12:48:26 +0800 CST

fstrim 不会在 cronjob 中运行

  • 0

我有以下 cronjob 设置

@daily /root/trim.sh

/root/trim.sh

fstrim -av

但它只是不运行。/root/trim.sh手动运行时会这样。它有chmod +x权限。这是什么原因造成的?

disk-management
  • 1 个回答
  • 120 Views
Martin Hope
Toodarday
Asked: 2020-05-19 12:57:19 +0800 CST

ext4 - 笔记本电脑无法检测到 Sandisk USB

  • 0

我最近将 Ubuntu 20.04 安装到 USB 上,并注意到我无法在“从 USB 启动”选项中看到它。我相信这是由于使用 ext4 文件系统安装它。我的笔记本电脑 Aspire 3 a315 似乎不支持它。

问题 2:预计 5 年内最常见的文件系统是什么?

所以我的第二个问题是关于未来的证明。预计未来 5 年内最常用于笔记本电脑的格式。NTFS 是一个不错的选择吗?我不是在询问性能,我只需要它可以使用以及笔记本电脑仍将使用的最可能格式是什么。

filesystem live-usb ext4
  • 1 个回答
  • 169 Views
Martin Hope
Toodarday
Asked: 2019-05-22 06:51:37 +0800 CST

以小时:分钟:秒为单位获取视频长度,将结果舍入到秒

  • 4

现在我正在使用以下命令来获取视频持续时间的输出

ffprobe -v error -show_entries format=duration -of default=noprint_wrappers=1:nokey=1 -sexagesimal 'video file.mp4'

结果是0:33:29.410000

我需要将此结果更改为以下内容

  • 额外的 0 必须在前面 0:33:29.410000
  • 秒数必须向上或向下舍入。最终输出应该是00:33:29
command-line video
  • 1 个回答
  • 1224 Views
Martin Hope
Toodarday
Asked: 2019-04-13 11:27:47 +0800 CST

ffmpeg - 每 x 秒水印淡入/淡出并调整视频分辨率

  • 2

我正在使用当前的 ffmpeg 命令来转换多个视频并创建一个水印,该水印是每 120 秒播放时间从右到左到右的滚动文本。

find /home/video/ -type f -execdir ffmpeg -i '{}' -filter:v "drawtext=fontfile=/root/FreeSans.ttf:text='QWERTY':[email protected]:fontsize=26:y=h-line_h-30:x=w/20*mod(t\,120),scale=854:480" -pix_fmt yuv420p -c:v libx264 -preset slow -b:v 1000k -minrate 500k -maxrate 2000k -bufsize 2000k -c:a aac -ar 44100 -b:a 128k -movflags +faststart '/home/video/new/{}.mp4' \;

我想修改水印,使它看起来像这样

在此处输入图像描述

我希望上面显示的文本每 120 秒淡出一次并持续 15 秒。是粗体格式和相同的颜色(黑色)。

“qwerty qwerty qwerty qwerty”新行
“qwerty qwerty qwerty qwerty”

我目前使用的当前命令的另一个问题是不同的视频帧。例如,如果视频只有 800x600,则文字会非常大。如果视频为 1920x1080,则文字会非常小。我希望根据帧速率调整文本大小。就屏幕尺寸而言,它应该看起来像上面那样。

ffmpeg
  • 1 个回答
  • 1623 Views
Martin Hope
Toodarday
Asked: 2019-03-29 10:07:49 +0800 CST

gparted - 创建分区表 + 旧数据消失后磁盘大小变小

  • 1

由于 msdos-partition-table-imposed 错误,我遇到了与在麻烦创建 3TB ext4 分区上发帖的人相同的问题

我得到的新的 6TB 驱动器仅由 Microsoft 发行 2TB,因此我启动到 gparted 的“设备->创建分区表并从列表中选择“gpt”。然后我重新启动到 Windows 和 G: 驱动器不再安装。我删除了 disk0 并在 Windows 磁盘管理中重新创建了它,但是正如您在下面的屏幕截图中看到的那样,磁盘大小仅为 5589GB。应该更多吗?

在执行此操作之前,我确实使用了大约 300GB 的数据,我想恢复这些数据,但 Windows 和 gparted 都无法检测到超过 5589GB 的数据。

在此处输入图像描述

partitioning gparted
  • 1 个回答
  • 238 Views
Martin Hope
Toodarday
Asked: 2019-03-22 09:42:20 +0800 CST

如何从长的随机视频中创建 30 秒的 GIF?

  • 9

我的文件夹中有数百个视频,我想为其制作 gif。每个视频长度不同,但所有视频都超过 30 秒。我想在视频过程中从视频中获取 10 个 3 秒的 gif 图像。例如,如果视频长度为 25 分钟,则应每 2.5 分钟(150 秒)拍摄3 秒的录制gif。

完成的 gif 文件还必须与视频同名,但以 .gif 结尾,所有视频都是 .mp4

GIF 应该是 560x340

用一个命令来做到这一点会很好。

ffmpeg mp4 gif
  • 1 个回答
  • 2621 Views
Martin Hope
Toodarday
Asked: 2016-10-18 09:42:53 +0800 CST

如何扩展我的 LVM 分区

  • 1

我已经在机器上安装了 Proxmox。我需要扩展/dev/mapper/pve-data未使用的空间/dev/sdb5

我怎样才能做到这一点?

fdisk -l

Disk /dev/ram0: 64 MiB, 67108864 bytes, 131072 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/ram1: 64 MiB, 67108864 bytes, 131072 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/ram2: 64 MiB, 67108864 bytes, 131072 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/ram3: 64 MiB, 67108864 bytes, 131072 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/ram4: 64 MiB, 67108864 bytes, 131072 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/ram5: 64 MiB, 67108864 bytes, 131072 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/ram6: 64 MiB, 67108864 bytes, 131072 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/ram7: 64 MiB, 67108864 bytes, 131072 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/ram8: 64 MiB, 67108864 bytes, 131072 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/ram9: 64 MiB, 67108864 bytes, 131072 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/ram10: 64 MiB, 67108864 bytes, 131072 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/ram11: 64 MiB, 67108864 bytes, 131072 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/ram12: 64 MiB, 67108864 bytes, 131072 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/ram13: 64 MiB, 67108864 bytes, 131072 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/ram14: 64 MiB, 67108864 bytes, 131072 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/ram15: 64 MiB, 67108864 bytes, 131072 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/sda: 223.6 GiB, 240057409536 bytes, 468862128 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: dos
Disk identifier: 0xfbd89a5c

Device     Boot    Start       End   Sectors  Size Id Type
/dev/sda1  *        4096  40962047  40957952 19.5G 83 Linux
/dev/sda2       40962048  43057151   2095104 1023M 82 Linux swap / Solaris
/dev/sda3       43057152 468854783 425797632  203G  f W95 Ext'd (LBA)
/dev/sda5       43059200 468854783 425795584  203G 8e Linux LVM

Disk /dev/sdb: 223.6 GiB, 240057409536 bytes, 468862128 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: dos
Disk identifier: 0xafd793e2

Device     Boot    Start       End   Sectors  Size Id Type
/dev/sdb1           4096  40962047  40957952 19.5G fd Linux raid autodetect
/dev/sdb2       40962048  43057151   2095104 1023M 82 Linux swap / Solaris
/dev/sdb3       43057152 468854783 425797632  203G  f W95 Ext'd (LBA)
/dev/sdb5       43059200 468854783 425795584  203G fd Linux raid autodetect

Disk /dev/mapper/pve-data: 199 GiB, 213708177408 bytes, 417398784 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
partitioning
  • 1 个回答
  • 751 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

  • 主页
  • 问题
    • 最新
    • 热门
  • 标签
  • 帮助

Footer

AskOverflow.Dev

关于我们

  • 关于我们
  • 联系我们

Legal Stuff

  • Privacy Policy

Language

  • Pt
  • Server
  • Unix

© 2023 AskOverflow.DEV All Rights Reserve