mirror of
https://github.com/LCTT/TranslateProject.git
synced 2025-03-03 01:10:13 +08:00
Merge remote-tracking branch 'LCTT/master'
This commit is contained in:
commit
5d1b2d7253
@ -1,18 +1,20 @@
|
||||
[#]: collector: (lujun9972)
|
||||
[#]: translator: (geekpi)
|
||||
[#]: reviewer: ( )
|
||||
[#]: publisher: ( )
|
||||
[#]: url: ( )
|
||||
[#]: reviewer: (wxy)
|
||||
[#]: publisher: (wxy)
|
||||
[#]: url: (https://linux.cn/article-11230-1.html)
|
||||
[#]: subject: (How to manipulate PDFs on Linux)
|
||||
[#]: via: (https://www.networkworld.com/article/3430781/how-to-manipulate-pdfs-on-linux.html)
|
||||
[#]: author: (Sandra Henry-Stocker https://www.networkworld.com/author/Sandra-Henry_Stocker/)
|
||||
|
||||
如何在 Linux 上操作 PDF
|
||||
如何在 Linux 命令行操作 PDF
|
||||
======
|
||||
pdftk 命令提供了许多命令行处理 PDF 的操作,包括合并页面、加密文件、添加水印、压缩文件,甚至还有修复 PDF 。
|
||||
![Toshiyuki IMAI \(CC BY-SA 2.0\)][1]
|
||||
|
||||
虽然 PDF 通常被认为是相当稳定的文件,但在 Linux 和其他系统上你可以做很多处理。包括合并、拆分、旋转、拆分单页、加密和解密、添加水印、压缩和解压缩,甚至还有修复。 **pdftk** 命令能执行所有甚至更多操作。
|
||||
> pdftk 命令提供了许多处理 PDF 的命令行操作,包括合并页面、加密文件、添加水印、压缩文件,甚至还有修复 PDF。
|
||||
|
||||

|
||||
|
||||
虽然 PDF 通常被认为是相当稳定的文件,但在 Linux 和其他系统上你可以做很多处理。包括合并、拆分、旋转、拆分成单页、加密和解密、添加水印、压缩和解压缩,甚至还有修复。 `pdftk` 命令能执行所有甚至更多操作。
|
||||
|
||||
“pdftk” 代表 “PDF 工具包”(PDF tool kit),这个命令非常易于使用,并且可以很好地操作 PDF。例如,要将独立的文件合并成一个文件,你可以使用以下命令:
|
||||
|
||||
@ -20,7 +22,7 @@ pdftk 命令提供了许多命令行处理 PDF 的操作,包括合并页面、
|
||||
$ pdftk pg1.pdf pg2.pdf pg3.pdf pg4.pdf pg5.pdf cat output OneDoc.pdf
|
||||
```
|
||||
|
||||
OneDoc.pdf 将包含上面显示的所有五个文档,命令将在几秒钟内运行完毕。请注意,**cat** 选项表示将文件连接在一起,**output** 选项指定新文件的名称。
|
||||
`OneDoc.pdf` 将包含上面显示的所有五个文档,命令将在几秒钟内运行完毕。请注意,`cat` 选项表示将文件连接在一起,`output` 选项指定新文件的名称。
|
||||
|
||||
你还可以从 PDF 中提取选定页面来创建单独的 PDF 文件。例如,如果要创建仅包含上面创建的文档的第 1、2、3 和 5 页的新 PDF,那么可以执行以下操作:
|
||||
|
||||
@ -28,7 +30,7 @@ OneDoc.pdf 将包含上面显示的所有五个文档,命令将在几秒钟内
|
||||
$ pdftk OneDoc.pdf cat 1-3 5 output 4pgs.pdf
|
||||
```
|
||||
|
||||
另外,如果你想要第 1、3、4 和 5 页,我们可以使用以下命令:
|
||||
另外,如果你想要第 1、3、4 和 5 页(总计 5 页),我们可以使用以下命令:
|
||||
|
||||
```
|
||||
$ pdftk OneDoc.pdf cat 1 3-end output 4pgs.pdf
|
||||
@ -36,13 +38,13 @@ $ pdftk OneDoc.pdf cat 1 3-end output 4pgs.pdf
|
||||
|
||||
你可以选择单独页面或者页面范围,如上例所示。
|
||||
|
||||
下一个命令将创建一个包含奇数页(1、3等)和一个包含偶数页(2、4等)的整合文档:
|
||||
下一个命令将从一个包含奇数页(1、3 等)的文件和一个包含偶数页(2、4 等)的文件创建一个整合文档:
|
||||
|
||||
```
|
||||
$ pdftk A=odd.pdf B=even.pdf shuffle A B output collated.pdf
|
||||
```
|
||||
|
||||
请注意,**shuffle** 选项使得能够完成整合,并指示文档的使用顺序。另请注意:虽然上面建议用的是奇数/偶数页,但你不限于仅使用两个文件。
|
||||
请注意,`shuffle` 选项使得能够完成整合,并指示文档的使用顺序。另请注意:虽然上面建议用的是奇数/偶数页,但你不限于仅使用两个文件。
|
||||
|
||||
如果要创建只能由知道密码的收件人打开的加密 PDF,可以使用如下命令:
|
||||
|
||||
@ -50,9 +52,9 @@ $ pdftk A=odd.pdf B=even.pdf shuffle A B output collated.pdf
|
||||
$ pdftk prep.pdf output report.pdf user_pw AsK4n0thingGeTn0thing
|
||||
```
|
||||
|
||||
选项提供 40(**encrypt_40bit**)和 128(**encrypt_128bit**)位加密。默认情况下使用 128 位加密。
|
||||
选项提供 40(`encrypt_40bit`)和 128(`encrypt_128bit`)位加密。默认情况下使用 128 位加密。
|
||||
|
||||
你还可以使用 **burst** 选项将 PDF 文件分成单个页面:
|
||||
你还可以使用 `burst` 选项将 PDF 文件分成单个页面:
|
||||
|
||||
```
|
||||
$ pdftk allpgs.pdf burst
|
||||
@ -64,9 +66,7 @@ $ ls -ltr *.pdf | tail -5
|
||||
-rw-rw-r-- 1 shs shs 23136 Aug 8 08:18 pg_0005.pdf
|
||||
```
|
||||
|
||||
**pdftk** 命令使得合并、拆分、重建、加密 PDF 文件非常容易。要了解更多选项,请查看 [PDF 实验室][3]中的示例页面
|
||||
|
||||
在 [Facebook][5] 和 [LinkedIn][6] 上加入 Network World 社区,发表你对热门主题的评论。
|
||||
`pdftk` 命令使得合并、拆分、重建、加密 PDF 文件非常容易。要了解更多选项,请查看 [PDF 实验室][3]中的示例页面。
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
@ -75,7 +75,7 @@ via: https://www.networkworld.com/article/3430781/how-to-manipulate-pdfs-on-linu
|
||||
作者:[Sandra Henry-Stocker][a]
|
||||
选题:[lujun9972][b]
|
||||
译者:[geekpi](https://github.com/geekpi)
|
||||
校对:[校对者ID](https://github.com/校对者ID)
|
||||
校对:[wxy](https://github.com/wxy)
|
||||
|
||||
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
|
||||
|
317
sources/talk/20180116 Command Line Heroes- Season 1- OS Wars.md
Normal file
317
sources/talk/20180116 Command Line Heroes- Season 1- OS Wars.md
Normal file
@ -0,0 +1,317 @@
|
||||
[#]: collector: (lujun9972)
|
||||
[#]: translator: (lujun9972)
|
||||
[#]: reviewer: ( )
|
||||
[#]: publisher: ( )
|
||||
[#]: url: ( )
|
||||
[#]: subject: (Command Line Heroes: Season 1: OS Wars)
|
||||
[#]: via: (https://www.redhat.com/en/command-line-heroes/season-1/os-wars-part-1)
|
||||
[#]: author: (redhat https://www.redhat.com)
|
||||
|
||||
Command Line Heroes: Season 1: OS Wars
|
||||
======
|
||||
Saron Yitbarek:
|
||||
|
||||
Some stories are so epic, with such high stakes , that in my head, it's like that crawling text at the start of a Star Wars movie. You know, like-
|
||||
|
||||
Voice Actor:
|
||||
|
||||
Episode One, The OS Wars.
|
||||
|
||||
Saron Yitbarek:
|
||||
|
||||
Yeah, like that.
|
||||
|
||||
Voice Actor:
|
||||
|
||||
[00:00:30]
|
||||
|
||||
It is a period of mounting tensions. The empires of Bill Gates and Steve Jobs careen toward an inevitable battle over proprietary software. Gates has formed a powerful alliance with IBM, while Jobs refuses to license his hardware or operating system. Their battle for dominance threatens to engulf the galaxy in an OS war. Meanwhile, in distant lands, and unbeknownst to the emperors, open source rebels have begun to gather.
|
||||
|
||||
Saron Yitbarek:
|
||||
|
||||
[00:01:00]
|
||||
|
||||
Okay. Maybe that's a bit dramatic, but when we're talking about the OS wars of the 1980s, '90s, and 2000s, it's hard to overstate things. There really was an epic battle for dominance. Steve Jobs and Bill Gates really did hold the fate of billions in their hands. Control the operating system, and you control how the vast majority of people use computers, how we communicate with each other, how we source information. I could go on, but you know all this. Control the OS, and you would be an emperor.
|
||||
|
||||
[00:01:30]
|
||||
|
||||
[00:02:00]
|
||||
|
||||
I'm Saron Yitbarek [00:01:24], and you're listening to Command Line Heroes, an original podcast from Red Hat. What is a Command Line Hero, you ask? Well, if you would rather make something than just use it, if you believe developers have the power to build a better future, if you want a world where we all get a say in how our technologies shape our lives, then you, my friend, are a command line hero. In this series, we bring you stories from the developers among us who are transforming tech from the command line up. And who am I to be guiding you on this trek? Who is Saron Yitbarek? Well, actually I'm guessing I'm a lot like you. I'm a developer for starters, and everything I do depends on open source software. It's my world. The stories we tell on this podcast are a way for me to get above the daily grind of my work, and see that big picture. I hope it does the same thing for you , too.
|
||||
|
||||
[00:02:30]
|
||||
|
||||
[00:03:00]
|
||||
|
||||
What I wanted to know right off the bat was, where did open source technology even come from? I mean, I know a fair bit about Linus Torvalds and the glories of L inux ® , as I'm sure you do , too, but really, there was life before open source, right? And if I want to truly appreciate the latest and greatest of things like DevOps and containers, and on and on, well, I feel like I owe it to all those earlier developers to know where this stuff came from. So, let's take a short break from worrying about memory leaks and buffer overflows. Our journey begins with the OS wars, the epic battle for control of the desktop. It was like nothing the world had ever seen, and I'll tell you why. First, in the age of computing, you've got exponentially scaling advantages for the big fish ; and second, there's never been such a battle for control on ground that's constantly shifting. Bill Gates and Steve Jobs? They don't know it yet, but by the time this story is halfway done, everything they're fighting for is going to change, evolve, and even ascend into the cloud.
|
||||
|
||||
[00:03:30]
|
||||
|
||||
[00:04:00]
|
||||
|
||||
Okay, it's the fall of 1983. I was negative six years old. Ronald Reagan was president, and the U . S . and the Soviet Union are threatening to drag the planet into nuclear war. Over at the Civic Center in Honolulu, it's the annual Apple sales conference. An exclusive bunch of Apple employees are waiting for Steve Jobs to get onstage. He's this super bright-eyed 28-year-old, and he's looking pretty confident. In a very serious voice, Jobs speaks into the mic and says that he's invited three industry experts to have a panel discussion on software. But the next thing that happens is not what you'd expect. Super cheesy '80s music fills the room. A bunch of multi-colored tube lights light up the stage, and then an announcer voice says-
|
||||
|
||||
Voice Actor:
|
||||
|
||||
And now, ladies and gentlemen, the Macintosh software dating game.
|
||||
|
||||
Saron Yitbarek:
|
||||
|
||||
[00:04:30]
|
||||
|
||||
[00:05:00]
|
||||
|
||||
Jobs has this big grin on his face as he reveals that the three CEOs on stage have to take turns wooing him. It's essentially an '80s version of The Bachelor, but for tech love. Two of the software bigwigs say their bit, and then it's over to contestant number three. Is that? Yup. A fresh - faced Bill Gates with large square glasses that cover half his face. He proclaims that during 1984, half of Microsoft's revenue is going to come from Macintosh software. The audience loves it, and gives him a big round of applause. What they don't know is that one month after this event, Bill Gates will announce his plans to release Windows 1.0. You'd never guess Jobs is flirting with someone who'd end up as Apple's biggest rival. But Microsoft and Apple are about to live through the worst marriage in tech history. They're going to betray each other, they're going to try and destroy each other, and they're going to be deeply, painfully bound to each other.
|
||||
|
||||
James Allworth:
|
||||
|
||||
[00:05:30]
|
||||
|
||||
I guess philosophically, one was more idealistic and focused on the user experience above all else, and was an integrated organization, whereas Microsoft much more pragmatic, a modular focus-
|
||||
|
||||
Saron Yitbarek:
|
||||
|
||||
That's James Allworth. He's a prolific tech writer who worked inside the corporate team of Apple Retail. Notice that definition of Apple he gives. An integrated organization. That sense of a company beholden only to itself. A company that doesn't want to rely on others. That's key.
|
||||
|
||||
James Allworth:
|
||||
|
||||
[00:06:00]
|
||||
|
||||
Apple was the integrated player, and it wanted to focus on a delightful user experience, and that meant that it wanted to control the entire stack and everything that was delivered, from the hardware to the operating system, to even some of the applications that ran on top of the operating system. That always served it well in periods where new innovations, important innovations, were coming to market where you needed to be across both hardware and software, and where being able to change the hardware based on what you wanted to do and what t was new in software was an advantage. For example-
|
||||
|
||||
[00:06:30]
|
||||
|
||||
Saron Yitbarek:
|
||||
|
||||
[00:07:00]
|
||||
|
||||
A lot of people loved that integration, and became die hard Apple fans. Plenty of others stuck with Microsoft. Back to that sales conference in Honolulu. At that very same event, Jobs gave his audience a sneak peek at the Superbowl ad he was about to release. You might have seen it for yourself. Think George Orwell's 1984. In this cold and gray world, mindless automatons are shuffling along under a dictator's projected gaze. They represent IBM users. Then, beautiful, athletic Anya Major, representing Apple, comes running through the hall in full color. She hurls her sledgehammer at Big Brother's screen, smashing it to bits. Big Brother's spell is broken, and a booming voice tells us that Apple is about to introduce the Macintosh.
|
||||
|
||||
Voice Actor:
|
||||
|
||||
And you'll see why 1984 will not be like 1984.
|
||||
|
||||
Saron Yitbarek:
|
||||
|
||||
[00:07:30]
|
||||
|
||||
And yeah, looking back at that commercial, the idea that Apple was a freedom fighter working to set the masses free is a bit much. But the thing hit a nerve. Ken Segal worked at the advertising firm that made the commercial for Apple. He was Steve Jobs' advertising guy for more than a decade in the early days.
|
||||
|
||||
Ken Segal:
|
||||
|
||||
[00:08:00]
|
||||
|
||||
Well, the 1984 commercial came with a lot of risk. In fact, it was so risky that Apple didn't want to run it when they saw it. You've probably heard stories that Steve liked it, but the Apple board did not like it. In fact, they were so outraged that so much money had been spent on such a thing that they wanted to fire the ad agency. Steve was the one sticking up for the agency.
|
||||
|
||||
Saron Yitbarek:
|
||||
|
||||
Jobs, as usual, knew a good mythology when he saw one.
|
||||
|
||||
Ken Segal:
|
||||
|
||||
That commercial struck such a chord within the company, within the industry, that it became this thing for Apple. Whether or not people were buying computers that day, it had a sort of an aura that stayed around for years and years and years, and helped define the character of the company. We're the rebels. We're the guys with the sledgehammer.
|
||||
|
||||
[00:08:30]
|
||||
|
||||
Saron Yitbarek:
|
||||
|
||||
So in their battle for the hearts and minds of literally billions of potential consumers, the emperors of Apple and Microsoft were learning to frame themselves as redeemers. As singular heroes. As lifestyle choices. But Bill Gates knew something that Apple had trouble understanding. This idea that in a wired world, nobody, not even an emperor, can really go it alone.
|
||||
|
||||
[00:09:00]
|
||||
|
||||
[00:09:30]
|
||||
|
||||
June 25th, 1985. Gates sends a memo to Apple's then CEO John Scully. This was during the wilderness years. Jobs had just been excommunicated, and wouldn't return to Apple until 1996. Maybe it was because Jobs was out that Gates felt confident enough to write what he wrote. In the memo, he encourages Apple to license their OS to clone makers. I want to read a bit from the end of the memo, just to give you a sense of how perceptive it was. Gates writes, "It is now impossible for Apple to create a standard out of their innovative technology without support from other personal computer manufacturers. Apple must open the Macintosh architecture to have the independent support required to gain momentum and establish a standard." In other words, no more operating in a silo, you guys. You've got to be willing to partner with others. You have to work with developers.
|
||||
|
||||
[00:10:00]
|
||||
|
||||
[00:10:30]
|
||||
|
||||
You see this philosophy years later, when Microsoft CEO Steve Ballmer gets up on stage to give a keynote and he starts shouting, "Developers, developers, developers, developers, developers, developers. Developers, developers, developers, developers, developers, developers, developers, developers." You get the idea. Microsoft likes developers. Now, they're not about to share source code with them, but they do want to build this whole ecosystem of partners. And when Bill Gates suggests that Apple do the same, as you might have guessed, the idea is tossed out the window. Apple had drawn a line in the sand, and five months after they trashed Gates' memo, Microsoft released Windows 1.0. The war was on.
|
||||
|
||||
Developers, developers, developers, developers, developers, developers, developers, developers, developers, developers, developers, developers, developers, developers, developers, developers, developers, developers.
|
||||
|
||||
[00:11:00]
|
||||
|
||||
You're listening to Command Line Heroes, an original podcast from Red Hat. In this inaugural episode, we go back in time to relive the epic story of the OS wars, and we're going to find out, how did a war between tech giants clear the way for the open source world we all live in today?
|
||||
|
||||
[00:11:30]
|
||||
|
||||
Okay, a little backstory. Forgive me if you've heard this one, but it's a classic. It's 1979, and Steve Jobs drives up to the Xerox Park research center in Palo Alto. The engineers there have been developing this whole fleet of elements for what they call a graphical user interface. Maybe you've heard of it. They've got menus, they've got scroll bars, they've got buttons and folders and overlapping windows. It was a beautiful new vision of what a computer interface could look like. And nobody had any of this stuff. Author and journalist Steven Levy talks about its potential.
|
||||
|
||||
Steven Levy:
|
||||
|
||||
[00:12:00]
|
||||
|
||||
There was a lot of excitement about this new interface that was going to be much friendlier than what we had before, which used what was called the command line, where there was really no interaction between you and the computer in the way you'd interact with something in real life. The mouse and the graphics on the computer gave you a way to do that, to point to something just like you'd point to something in real life. It made it a lot easier. You didn't have to memorize all these codes.
|
||||
|
||||
Saron Yitbarek:
|
||||
|
||||
[00:12:30]
|
||||
|
||||
[00:13:00]
|
||||
|
||||
Except, the Xerox executives did not get that they were sitting on top of a platinum mine. The engineers were more aware than the execs. Typical. So those engineers were, yeah, a little stressed out that they were instructed to show Jobs how everything worked. But the executives were calling the shots. Jobs felt, quote, "The product genius that brought them to that monopolistic position gets rotted out by people running these companies that have no conception of a good product versus a bad product." That's sort of harsh, but hey, Jobs walked out of that meeting with a truckload of ideas that Xerox executives had missed. Pretty much everything he needed to revolutionize the desktop computing experience. Apple releases the Lisa in 1983, and then the Mac in 1984. These devices are made by the ideas swiped from Xerox.
|
||||
|
||||
[00:13:30]
|
||||
|
||||
What's interesting to me is Jobs' reaction to the claim that he stole the GUI. He's pretty philosophical about it. He quotes Picasso, saying, "Good artists copy, great artists steal." He tells one reporter, "We have always been shameless about stealing great ideas." Great artists steal. Okay. I mean, we're not talking about stealing in a hard sense. Nobody's obtaining proprietary source code and blatantly incorporating it into their operating system. This is softer, more like idea borrowing. And that's much more difficult to control, as Jobs himself was about to learn. Legendary software wizard, and true command line hero, Andy Hertzfeld, was an original member of the Macintosh development team.
|
||||
|
||||
[00:14:00]
|
||||
|
||||
Andy Hertzfeld:
|
||||
|
||||
[00:14:30]
|
||||
|
||||
[00:15:00]
|
||||
|
||||
Yeah, Microsoft was our first software partner with the Macintosh. At the time, we didn't really consider them a competitor. They were the very first company outside of Apple that we gave Macintosh prototypes to. I talked with the technical lead at Microsoft usually once a week. They were the first outside party trying out the software that we wrote. They gave us very important feedback, and in general I would say the relationship was pretty good. But I also noticed in my conversations with the technical lead, he started asking questions that he didn't really need to know about how the system was implemented, and I got the idea that they were trying to copy the Macintosh. I t old Steve Jobs about it pretty early on, but it really came to a head in the fall of 1983. We discovered that they actually, without telling us ahead of time, they announced Windows at the COMDEX in November 1983 and Steve Jobs hit the roof. He really considered that a betrayal.
|
||||
|
||||
Saron Yitbarek:
|
||||
|
||||
[00:15:30]
|
||||
|
||||
[00:16:00]
|
||||
|
||||
As newer versions of Windows were released, it became pretty clear that Microsoft had lifted from Apple all the ideas that Apple had lifted from Xerox. Jobs was apoplectic. His Picasso line about how great artists steal. Yeah. That goes out the window. Though maybe Gates was using it now. Reportedly, when Jobs screamed at Gates that he'd stolen from them, Gates responded, "Well Steve, I think it's more like we both had this rich neighbor named Xerox, and I broke into his house to steal the TV set, and found out that you'd already stolen it." Apple ends up suing Microsoft for stealing the look and feel of their GUI. The case goes on for years, but in 1993, a judge from the 9th Circuit Court of Appeals finally sides with Microsoft. Judge Vaughn Walker declares that look and feel are not covered by copyright. This is super important. That decision prevented Apple from creating a monopoly with the interface that would dominate desktop computing. Soon enough, Apple's brief lead had vanished. Here's Steven Levy's take.
|
||||
|
||||
Steven Levy:
|
||||
|
||||
[00:16:30]
|
||||
|
||||
[00:17:00]
|
||||
|
||||
They lost the lead not because of intellectual property theft on Microsoft's part, but because they were unable to consolidate their advantage in having a better operating system during the 1980s. They overcharged for their computers, quite frankly. So Microsoft had been developing Windows, starting with the mid-1980s, but it wasn't until Windows 3 in 1990, I believe, where they really came across with a version that was ready for prime time. Ready for masses of people to use. At that point is where Microsoft was able to migrate huge numbers of people, hundreds of millions, over to the graphical interface in a way that Apple had not been able to do. Even though they had a really good operating system, they used it since 1984.
|
||||
|
||||
Saron Yitbarek:
|
||||
|
||||
[00:17:30]
|
||||
|
||||
[00:18:00]
|
||||
|
||||
Microsoft now dominated the OS battlefield. They held 90% of the market, and standardized their OS across a whole variety of PCs. The future of the OS looked like it'd be controlled by Microsoft. And then? Well, at the 1997 Macworld Expo in Boston, you have an almost bankrupt Apple. A more humble Steve Jobs gets on stage, and starts talking about the importance of partnerships, and one in particular, he says, has become very, very meaningful. Their new partnership with Microsoft. Steve Jobs is calling for a détente, a ceasefire. Microsoft could have their enormous market share. If we didn't know better, we might think we were entering a period of peace in the kingdom. But when stakes are this high, it's never that simple. Just as Apple and Microsoft were finally retreating to their corners, pretty bruised from decades of fighting, along came a 21-year-old Finnish computer science student who, almost by accident, changed absolutely everything.
|
||||
|
||||
I'm Saron Yitbarek, and this is Command Line Heroes.
|
||||
|
||||
[00:18:30]
|
||||
|
||||
While certain tech giants were busy bashing each other over proprietary software, there were new champions of free and open source software popping up like mushrooms. One of these champions was Richard Stallman. You're probably familiar with his work. He wanted free software and a free society. That's free as in free speech, not free as in free beer. Back in the '80s, Stallman saw that there was no viable alternative to pricey, proprietary OSs, like UNIX . So, he decided to make his own. Stallman's Free Software Foundation developed GNU, which stood for GNU's not UNIX , of course. It'd be an OS like UNIX, but free of all UNIX code, and free for users to share.
|
||||
|
||||
[00:19:00]
|
||||
|
||||
[00:19:30]
|
||||
|
||||
Just to give you a sense of how important that idea of free software was in the 1980s, the companies that owned the UNIX code at different points, AT&T Bell Laboratories and then UNIX System Laboratories, they threatened lawsuits on anyone making their own OS after looking at UNIX source code. These guys were next - level proprietary. All those programmers were, in the words of the two companies, "mentally contaminated," because they'd seen UNIX code. In a famous court case between UNIX System Laboratories and Berkeley Software Design, it was argued that any functionally similar system, even though it didn't use the UNIX code itself, was a bre a ch of copyright. Paul Jones was a developer at that time. He's now the director of the digital library ibiblio.org.
|
||||
|
||||
Paul Jones:
|
||||
|
||||
[00:20:00]
|
||||
|
||||
Anyone who has seen any of the code is mentally contaminated was their argument. That would have made almost anyone who had worked on a computer operating system that involved UNIX , in any computer science department, was mentally contaminated. So in one year at USENIX, we all got little white bar pin s with red letters that say mentally contaminated, and we all wear those around to our own great pleasure, to show that we were sticking it to Bell because we were mentally contaminated.
|
||||
|
||||
[00:20:30]
|
||||
|
||||
Saron Yitbarek:
|
||||
|
||||
[00:21:00]
|
||||
|
||||
The whole world was getting mentally contaminated. Staying pure, keeping things nice and proprietary, that old philosophy was getting less and less realistic. It was into this contaminated reality that one of history's biggest command line heroes was born, a boy in Finland named Linus Torvalds. If this is Star Wars, then Linus Torvalds is our Luke Skywalker. He was a mild-mannered grad student at the University of Helsinki. Talented, but lacking in grand visions. The classic reluctant hero. And, like any young hero, he was also frustrated. He wanted to incorporate the 386 processor into his new PC's functions. He wasn't impressed by the MS-DOS running on his IBM clone, and he couldn't afford the $5,000 price tag on the UNIX software that would have given him some programming freedom. The solution, which Torvalds crafted on MINIX in the spring of 1991, was an OS kernel called Linux. The kernel of an OS of his very own.
|
||||
|
||||
[00:21:30]
|
||||
|
||||
Steven Vaughan-Nichols:
|
||||
|
||||
Linus Torvalds really just wanted to have something to play with.
|
||||
|
||||
Saron Yitbarek:
|
||||
|
||||
Steven Vaughan-Nichols is a contributing editor at ZDNet.com, and he's been writing about the business of technology since there was a business of technology.
|
||||
|
||||
Steven Vaughan-Nichols:
|
||||
|
||||
[00:22:00]
|
||||
|
||||
[00:22:30]
|
||||
|
||||
There were a couple of operating systems like it at the time. The main one that he was concerned about was called MINIX. That was an operating system that was meant for students to learn how to build operating systems. Linus looked at that, and thought that it was interesting, but he wanted to build his own. So it really started as a do-it-yourself project at Helsinki. That's how it all started, is just basically a big kid playing around and learning how to do things. But what was different in his case is that he was both bright enough and persistent enough, and also friendly enough to get all these other people working on it, and then he started seeing the project through. 27 years later, it is much, much bigger than he ever dreamed it would be.
|
||||
|
||||
Saron Yitbarek:
|
||||
|
||||
[00:23:00]
|
||||
|
||||
By the fall of 1991, Torvalds releases 10,000 lines of code, and people around the world start offering comments, then tweaks, additions, edits. That might seem totally normal to you as a developer today, but remember, at that time, open collaboration like that was a moral affront to the whole proprietary system that Microsoft, Apple, and IBM had done so well by. Then that openness gets enshrined. Torvalds places Linux under the GNU general public license. The license that had kept Stallman's GNU system free was now going to keep Linux free , too. The importance of that move to incorporate GPL, basically preserving the freedom and openness of the software forever, cannot be overstated. Vaughan-Nichols explains.
|
||||
|
||||
[00:23:30]
|
||||
|
||||
Steven Vaughan-Nichols:
|
||||
|
||||
In fact, by the license that it's under, which is called GPL version 2, you have to share the code if you're going to try to sell it or present it to the world, so that if you make an improvement, it's not enough just to give someone the improvement. You actually have to share with them the nuts and bolts of all those changes. Then they are adapted into Linux if they're good enough.
|
||||
|
||||
Saron Yitbarek:
|
||||
|
||||
[00:24:00]
|
||||
|
||||
That public approach proved massively attractive. Eric Raymond, one of the early evangelists of the movement wrote in his famous essay that, "Corporations like Microsoft and Apple have been trying to build software cathedrals, while Linux and its kind were offering a great babbling bazaar of different agendas and approaches. The bazaar was a lot more fun than the cathedral."
|
||||
|
||||
Stormy Peters:
|
||||
|
||||
I think at the time, what attracted people is that they were going to be in control of their own world.
|
||||
|
||||
Saron Yitbarek:
|
||||
|
||||
Stormy Peters is an industry analyst, and an advocate for free and open source software.
|
||||
|
||||
[00:24:30]
|
||||
|
||||
Stormy Peters:
|
||||
|
||||
[00:25:00]
|
||||
|
||||
When open source software first came out, the OS was all proprietary. You couldn't even add a printer without going through proprietary software. You couldn't add a headset. You couldn't develop a small hardware device of your own, and make it work with your laptop. You couldn't even put in a DVD and copy it, because you couldn't change the software. Even if you owned the DVD, you couldn't copy it. You had no control over this hardware/software system that you'd bought. You couldn't create anything new and bigger and better out of it. That's why an open source operating system was so important at the beginning. We needed an open source collaborative environment where we could build bigger and better things.
|
||||
|
||||
Saron Yitbarek:
|
||||
|
||||
[00:25:30]
|
||||
|
||||
Mind you, Linux isn't a purely egalitarian utopia. Linus Torvalds doesn't approve everything that goes into the kernel, but he does preside over its changes. He's installed a dozen or so people below him to manage different parts of the kernel. They, in turn, trust people under themselves, and so on, in a pyramid of trust. Changes might come from anywhere, but they're all judged and curated.
|
||||
|
||||
[00:26:00]
|
||||
|
||||
It is amazing, though, to think how humble, and kind of random, Linus' DIY project was to begin with. He didn't have a clue he was the Luke Skywalker figure in all this. He was just 21, and had been programming half his life. But this was the first time the silo opened up, and people started giving him feedback. Dozens, then hundreds, and thousands of contributors. With crowdsourcing like that, it doesn't take long before Linux starts growing. Really growing. It even finally gets noticed by Microsoft. Their CEO, Steve Ballmer, called Linux, and I quote, "A cancer that attaches itself in an intellectual property sense to everything it touches." Steven Levy describes where Ballmer was coming from.
|
||||
|
||||
Steven Levy:
|
||||
|
||||
[00:26:30]
|
||||
|
||||
Once Microsoft really solidified its monopoly, and indeed it was judged in federal court as a monopoly, anything that could be a threat to that, they reacted very strongly to. So of course, the idea that free software would be emerging, when they were charging for software, they saw as a cancer. They tried to come up with an intellectual property theory about why this was going to be bad for consumers.
|
||||
|
||||
Saron Yitbarek:
|
||||
|
||||
[00:27:00]
|
||||
|
||||
Linux was spreading, and Microsoft was worried. By 2006, Linux would become the second most widely used operating system after Windows, with about 5,000 developers working on it worldwide. Five thousand. Remember that memo that Bill Gates sent to Apple, the one where he's lecturing them about the importance of partnering with other people? Turns out, open source would take that idea of partnerships to a whole new level, in a way Bill Gates would have never foreseen.
|
||||
|
||||
[00:27:30]
|
||||
|
||||
[00:28:00]
|
||||
|
||||
We've been talking about these huge battles for the OS, but so far, the unsung heroes, the developers, haven't fully made it onto the battlefield. That changes next time, on Command Line Heroes. In episode two, part two of the OS wars, it's the rise of Linux. Businesses wake up, and realize the importance of developers. These open source rebels grow stronger, and the battlefield shifts from the desktop to the server room. There's corporate espionage, new heroes, and the unlikeliest change of heart in tech history. It all comes to a head in the concluding half of the OS wars.
|
||||
|
||||
[00:28:30]
|
||||
|
||||
To get new episodes of Command Line Heroes delivered automatically for free, make sure you hit subscribe on Apple podcasts, Spotify, Google Play, or however you get your podcasts. Over the rest of the season, we're visiting the latest battlefields, the up-for-grab territories where the next generation of Command Line Heroes are making their mark. For more info, check us out at redhat.com/commandlineheroes. I'm Saron Yitbarek. Until next time, keep on coding.
|
||||
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
via: https://www.redhat.com/en/command-line-heroes/season-1/os-wars-part-1
|
||||
|
||||
作者:[redhat][a]
|
||||
选题:[lujun9972][b]
|
||||
译者:[译者ID](https://github.com/译者ID)
|
||||
校对:[校对者ID](https://github.com/校对者ID)
|
||||
|
||||
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
|
||||
|
||||
[a]: https://www.redhat.com
|
||||
[b]: https://github.com/lujun9972
|
@ -0,0 +1,93 @@
|
||||
[#]: collector: (lujun9972)
|
||||
[#]: translator: ( )
|
||||
[#]: reviewer: ( )
|
||||
[#]: publisher: ( )
|
||||
[#]: url: ( )
|
||||
[#]: subject: (Fix ‘E: The package cache file is corrupted, it has the wrong hash’ Error In Ubuntu)
|
||||
[#]: via: (https://www.ostechnix.com/fix-e-the-package-cache-file-is-corrupted-it-has-the-wrong-hash-error-in-ubuntu/)
|
||||
[#]: author: (sk https://www.ostechnix.com/author/sk/)
|
||||
|
||||
Fix ‘E: The package cache file is corrupted, it has the wrong hash’ Error In Ubuntu
|
||||
======
|
||||
|
||||
Today, I tried to update the repository lists in my Ubuntu 18.04 LTS desktop and got an error that says – **E: The package cache file is corrupted, it has the wrong hash**. Here is what I run from the Terminal and its output:
|
||||
|
||||
```
|
||||
$ sudo apt update
|
||||
```
|
||||
|
||||
Sample output:
|
||||
|
||||
```
|
||||
Hit:1 http://it-mirrors.evowise.com/ubuntu bionic InRelease
|
||||
Hit:2 http://it-mirrors.evowise.com/ubuntu bionic-updates InRelease
|
||||
Hit:3 http://it-mirrors.evowise.com/ubuntu bionic-backports InRelease
|
||||
Hit:4 http://it-mirrors.evowise.com/ubuntu bionic-security InRelease
|
||||
Hit:5 http://ppa.launchpad.net/alessandro-strada/ppa/ubuntu bionic InRelease
|
||||
Hit:7 http://ppa.launchpad.net/leaeasy/dde/ubuntu bionic InRelease
|
||||
Hit:8 http://ppa.launchpad.net/rvm/smplayer/ubuntu bionic InRelease
|
||||
Ign:6 https://dl.bintray.com/etcher/debian stable InRelease
|
||||
Get:9 https://dl.bintray.com/etcher/debian stable Release [3,674 B]
|
||||
Fetched 3,674 B in 3s (1,196 B/s)
|
||||
Reading package lists... Done
|
||||
E: The package cache file is corrupted, it has the wrong hash
|
||||
```
|
||||
|
||||
![][2]
|
||||
|
||||
“The package cache file is corrupted, it has the wrong hash” Error In Ubuntu
|
||||
|
||||
After couple Google searches, I found a workaround to fix this error.
|
||||
|
||||
If you ever encountered with this error, don’t panic. Just run the following commands to fix it.
|
||||
|
||||
Before running the following command, **double check you have added “*” at the end**. It is very important to add ***** at the end of this command. If you don’t add it, it will delete **/var/lib/apt/lists/** directory and there is no way to bring it back. You have been warned!
|
||||
|
||||
```
|
||||
$ sudo rm -rf /var/lib/apt/lists/*
|
||||
```
|
||||
|
||||
Now I tried again to update the system using command:
|
||||
|
||||
```
|
||||
$ sudo apt update
|
||||
```
|
||||
|
||||
![][3]
|
||||
|
||||
This time it works!! Hope this helps.
|
||||
|
||||
* * *
|
||||
|
||||
**Suggested read:**
|
||||
|
||||
* [**How To Fix Broken Ubuntu OS Without Reinstalling It**][4]
|
||||
* [**How to fix “Package operation failed” Error in Ubuntu**][5]
|
||||
* [**Fix “dpkg: error: parsing file ‘/var/lib/dpkg/updates/0014′” Error In Ubuntu**][6]
|
||||
* [**How To Fix “Kernel driver not installed (rc=-1908)” VirtualBox Error In Ubuntu**][7]
|
||||
* [**How to fix ‘Failed to install the Extension pack’ error in Ubuntu**][8]
|
||||
|
||||
|
||||
|
||||
* * *
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
via: https://www.ostechnix.com/fix-e-the-package-cache-file-is-corrupted-it-has-the-wrong-hash-error-in-ubuntu/
|
||||
|
||||
作者:[sk][a]
|
||||
选题:[lujun9972][b]
|
||||
译者:[译者ID](https://github.com/译者ID)
|
||||
校对:[校对者ID](https://github.com/校对者ID)
|
||||
|
||||
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
|
||||
|
||||
[a]: https://www.ostechnix.com/author/sk/
|
||||
[b]: https://github.com/lujun9972
|
||||
[2]: https://www.ostechnix.com/wp-content/uploads/2019/08/The-package-cache-file-is-corrupted.png
|
||||
[3]: https://www.ostechnix.com/wp-content/uploads/2019/08/apt-update-command-output-in-Ubuntu.png
|
||||
[4]: https://www.ostechnix.com/how-to-fix-broken-ubuntu-os-without-reinstalling-it/
|
||||
[5]: https://www.ostechnix.com/how-to-fix-package-operation-failed-error-in-ubuntu/
|
||||
[6]: https://www.ostechnix.com/fix-dpkg-error-parsing-file-var-lib-dpkg-updates-0014-error-in-ubuntu/
|
||||
[7]: https://www.ostechnix.com/how-to-fix-kernel-driver-not-installed-rc-1908-virtualbox-error-in-ubuntu/
|
||||
[8]: https://www.ostechnix.com/some-softwares-are-not-working-after-uninstall-moksha-desktop-from-ubuntu-14-04-lts/
|
@ -0,0 +1,143 @@
|
||||
[#]: collector: (lujun9972)
|
||||
[#]: translator: ( )
|
||||
[#]: reviewer: ( )
|
||||
[#]: publisher: ( )
|
||||
[#]: url: ( )
|
||||
[#]: subject: (How To Change Linux Console Font Type And Size)
|
||||
[#]: via: (https://www.ostechnix.com/how-to-change-linux-console-font-type-and-size/)
|
||||
[#]: author: (sk https://www.ostechnix.com/author/sk/)
|
||||
|
||||
How To Change Linux Console Font Type And Size
|
||||
======
|
||||
|
||||
It is quite easy to change the text font type and its size if you have graphical desktop environment. How would you do that in an Ubuntu headless server that doesn’t have a graphical environment? No worries! This brief guide describes how to change Linux console font and size. This can be useful for those who don’t like the default font type/size or who prefer different fonts in general.
|
||||
|
||||
### Change Linux Console Font Type And Size
|
||||
|
||||
Just in case you don’t know yet, this is how a headless Ubuntu Linux server console looks like.
|
||||
|
||||
![][2]
|
||||
|
||||
Ubuntu Linux console
|
||||
|
||||
As far as I know, we can [**list the installed fonts**][3], but there is no option to change the font type or its size from Linux console as we do in the Terminal emulators in GUI desktop.
|
||||
|
||||
But that doesn’t mean that we can’t change it. We still can change the console fonts.
|
||||
|
||||
If you’re using Debian, Ubuntu and other DEB-based systems, you can use **“console-setup”** configuration file for **setupcon** which is used to configure font and keyboard layout for the console. The standard location of the console-setup configuration file is **/etc/default/console- setup**.
|
||||
|
||||
Now, run the following command to setup font for your Linux console.
|
||||
|
||||
```
|
||||
$ sudo dpkg-reconfigure console-setup
|
||||
```
|
||||
|
||||
Choose the encoding to use on your Linux console. Just leave the default values, choose OK and hit ENTER to continue.
|
||||
|
||||
![][4]
|
||||
|
||||
Choose encoding to set on the console in Ubuntu
|
||||
|
||||
Next choose the character set that should be supported by the console font from the list. By default, it was the the last option i.e. **Guess optimal character set** in my system. Just leave it as default and hit ENTER key.
|
||||
|
||||
![][5]
|
||||
|
||||
Choose character set in Ubuntu
|
||||
|
||||
Next choose the font for your console and hit ENTER key. Here, I am choosing “TerminusBold”.
|
||||
|
||||
![][6]
|
||||
|
||||
Choose font for your Linux console
|
||||
|
||||
In this step, we choose the desired font size for our Linux console.
|
||||
|
||||
![][7]
|
||||
|
||||
Choose font size for your Linux console
|
||||
|
||||
After a few seconds, the selected font with size will applied for your Linux console.
|
||||
|
||||
This is how console fonts looked like in my Ubuntu 18.04 LTS server before changing the font type and size.
|
||||
|
||||
![][8]
|
||||
|
||||
This is after changing the font type and size.
|
||||
|
||||
![][9]
|
||||
|
||||
As you can see, the text size is much bigger, better and the font type is different that default one.
|
||||
|
||||
You can also directly edit **/etc/default/console-setup** file and set the font type and size as you wish. As per the following example, my Linux console font type is “Terminus Bold” and font size is 32.
|
||||
|
||||
```
|
||||
ACTIVE_CONSOLES="/dev/tty[1-6]"
|
||||
CHARMAP="UTF-8"
|
||||
CODESET="guess"
|
||||
FONTFACE="TerminusBold"
|
||||
FONTSIZE="16x32"
|
||||
```
|
||||
|
||||
* * *
|
||||
|
||||
**Suggested read:**
|
||||
|
||||
* [**How To Switch Between TTYs Without Using Function Keys In Linux**][10]
|
||||
|
||||
|
||||
|
||||
* * *
|
||||
|
||||
##### Display Console fonts
|
||||
|
||||
To show your console font, simply type:
|
||||
|
||||
```
|
||||
$ showconsolefont
|
||||
```
|
||||
|
||||
This command will show a table of glyphs or letters of a font.
|
||||
|
||||
![][11]
|
||||
|
||||
Show console fonts
|
||||
|
||||
If your Linux distribution does not have “console-setup”, you can get it from [**here**][12].
|
||||
|
||||
On Linux distributions that uses **Systemd** , you can change the console font by editing **“/etc/vconsole.conf”** file.
|
||||
|
||||
Here is an example configuration for German keyboard.
|
||||
|
||||
```
|
||||
$ vi /etc/vconsole.conf
|
||||
|
||||
KEYMAP=de-latin1
|
||||
FONT=Lat2-Terminus16
|
||||
```
|
||||
|
||||
Hope you find this useful.
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
via: https://www.ostechnix.com/how-to-change-linux-console-font-type-and-size/
|
||||
|
||||
作者:[sk][a]
|
||||
选题:[lujun9972][b]
|
||||
译者:[译者ID](https://github.com/译者ID)
|
||||
校对:[校对者ID](https://github.com/校对者ID)
|
||||
|
||||
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
|
||||
|
||||
[a]: https://www.ostechnix.com/author/sk/
|
||||
[b]: https://github.com/lujun9972
|
||||
[2]: https://www.ostechnix.com/wp-content/uploads/2019/08/Ubuntu-Linux-console.png
|
||||
[3]: https://www.ostechnix.com/find-installed-fonts-commandline-linux/
|
||||
[4]: https://www.ostechnix.com/wp-content/uploads/2019/08/Choose-encoding-to-set-on-the-console.png
|
||||
[5]: https://www.ostechnix.com/wp-content/uploads/2019/08/Choose-character-set-in-Ubuntu.png
|
||||
[6]: https://www.ostechnix.com/wp-content/uploads/2019/08/Choose-font-for-Linux-console.png
|
||||
[7]: https://www.ostechnix.com/wp-content/uploads/2019/08/Choose-font-size-for-Linux-console.png
|
||||
[8]: https://www.ostechnix.com/wp-content/uploads/2019/08/Linux-console-tty-ubuntu-1.png
|
||||
[9]: https://www.ostechnix.com/wp-content/uploads/2019/08/Ubuntu-Linux-TTY-console.png
|
||||
[10]: https://www.ostechnix.com/how-to-switch-between-ttys-without-using-function-keys-in-linux/
|
||||
[11]: https://www.ostechnix.com/wp-content/uploads/2019/08/show-console-fonts.png
|
||||
[12]: https://software.opensuse.org/package/console-setup
|
@ -0,0 +1,103 @@
|
||||
[#]: collector: (lujun9972)
|
||||
[#]: translator: ( )
|
||||
[#]: reviewer: ( )
|
||||
[#]: publisher: ( )
|
||||
[#]: url: ( )
|
||||
[#]: subject: (How To Fix “Kernel driver not installed (rc=-1908)” VirtualBox Error In Ubuntu)
|
||||
[#]: via: (https://www.ostechnix.com/how-to-fix-kernel-driver-not-installed-rc-1908-virtualbox-error-in-ubuntu/)
|
||||
[#]: author: (sk https://www.ostechnix.com/author/sk/)
|
||||
|
||||
How To Fix “Kernel driver not installed (rc=-1908)” VirtualBox Error In Ubuntu
|
||||
======
|
||||
|
||||
I use Oracle VirtualBox to test various Linux and Unix distributions. I’ve tested hundred of virtual machines in VirtualBox so far. Today, I started Ubuntu 18.04 server VM in my Ubuntu 18.04 desktop and I got the following error.
|
||||
|
||||
```
|
||||
Kernel driver not installed (rc=-1908)
|
||||
|
||||
The VirtualBox Linux kernel driver (vboxdrv) is either not loaded or there is a permission problem with /dev/vboxdrv. Please reinstall virtualbox-dkms package and load the kernel module by executing
|
||||
|
||||
'modprobe vboxdrv'
|
||||
|
||||
as root.
|
||||
|
||||
where: suplibOsInit what: 3 VERR_VM_DRIVER_NOT_INSTALLED (-1908) - The support driver is not installed. On linux, open returned ENOENT.
|
||||
```
|
||||
|
||||
![][2]
|
||||
|
||||
“Kernel driver not installed (rc=-1908)” Error in Ubuntu
|
||||
|
||||
I clicked OK to close the message box and and I saw another one in the background.
|
||||
|
||||
```
|
||||
Failed to open a session for the virtual machine Ubuntu 18.04 LTS Server.
|
||||
|
||||
The virtual machine 'Ubuntu 18.04 LTS Server' has terminated unexpectedly during startup with exit code 1 (0x1).
|
||||
|
||||
Result Code:
|
||||
NS_ERROR_FAILURE (0x80004005)
|
||||
Component:
|
||||
MachineWrap
|
||||
Interface:
|
||||
IMachine {85cd948e-a71f-4289-281e-0ca7ad48cd89}
|
||||
```
|
||||
|
||||
![][3]
|
||||
|
||||
The virtual machine has terminated unexpectedly during startup with exit code 1 (0x1)
|
||||
|
||||
I didn’t know what to do first. I ran the following command to check if it helps.
|
||||
|
||||
```
|
||||
$ sudo modprobe vboxdrv
|
||||
```
|
||||
|
||||
And, I got this error.
|
||||
|
||||
```
|
||||
modprobe: FATAL: Module vboxdrv not found in directory /lib/modules/5.0.0-23-generic
|
||||
```
|
||||
|
||||
After carefully reading the both error messages, I realized that I should update the Virtualbox application.
|
||||
|
||||
If you ever run into this error in Ubuntu and its variants like Linux Mint, all you have to do is just reinstall or update the **“virtualbox-dkms”** package using command:
|
||||
|
||||
```
|
||||
$ sudo apt install virtualbox-dkms
|
||||
```
|
||||
|
||||
Or, it is much better to update the whole system:
|
||||
|
||||
```
|
||||
$ sudo apt upgrade
|
||||
```
|
||||
|
||||
Now the error has gone and I could start VMs from VirtualBox without any issues.
|
||||
|
||||
* * *
|
||||
|
||||
**Related read:**
|
||||
|
||||
* [**Solve “Result Code: NS_ERROR_FAILURE (0x80004005)” VirtualBox Error In Arch Linux**][4]
|
||||
|
||||
|
||||
|
||||
* * *
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
via: https://www.ostechnix.com/how-to-fix-kernel-driver-not-installed-rc-1908-virtualbox-error-in-ubuntu/
|
||||
|
||||
作者:[sk][a]
|
||||
选题:[lujun9972][b]
|
||||
译者:[译者ID](https://github.com/译者ID)
|
||||
校对:[校对者ID](https://github.com/校对者ID)
|
||||
|
||||
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
|
||||
|
||||
[a]: https://www.ostechnix.com/author/sk/
|
||||
[b]: https://github.com/lujun9972
|
||||
[2]: https://www.ostechnix.com/wp-content/uploads/2019/08/Kernel-driver-not-installed-virtualbox-ubuntu.png
|
||||
[3]: https://www.ostechnix.com/wp-content/uploads/2019/08/The-virtual-machine-has-terminated-unexpectedly-during-startup-with-exit-code-1-0x1.png
|
||||
[4]: https://www.ostechnix.com/solve-result-code-ns_error_failure-0x80004005-virtualbox-error-arch-linux/
|
@ -0,0 +1,184 @@
|
||||
[#]: collector: (lujun9972)
|
||||
[#]: translator: ( )
|
||||
[#]: reviewer: ( )
|
||||
[#]: publisher: ( )
|
||||
[#]: url: ( )
|
||||
[#]: subject: (How To Setup Multilingual Input Method On Ubuntu)
|
||||
[#]: via: (https://www.ostechnix.com/how-to-setup-multilingual-input-method-on-ubuntu/)
|
||||
[#]: author: (sk https://www.ostechnix.com/author/sk/)
|
||||
|
||||
How To Setup Multilingual Input Method On Ubuntu
|
||||
======
|
||||
|
||||
For those who don’t know, there are hundreds of spoken languages in India and 22 languages are listed as official languages in Indian constitution. I am not a native English speaker, so I often use **Google translate** if I ever needed to type and/or translate something from English to my native language, which is Tamil. Well, I guess I don’t need to rely on Google translate anymore. I just found way to type in Indian languages on Ubuntu. This guide explains how to setup multilingual input method. It has been exclusively written for Ubuntu 18.04 LTS, however it might work on other Ubuntu variants like Linux mint, Elementary OS.
|
||||
|
||||
### Setup Multilingual Input Method On Ubuntu Linux
|
||||
|
||||
With the help of **IBus** , we can easily setup multilingual input method on Ubuntu and its derivatives. Ibus, stands for **I** ntelligent **I** nput **Bus** , is an input method framework for multilingual input in Unix-like operating systems. It allows us to type in our native language in most GUI applications, for example LibreOffice.
|
||||
|
||||
##### Install IBus On Ubuntu
|
||||
|
||||
To install IBus package on Ubuntu, run:
|
||||
|
||||
```
|
||||
$ sudo apt install ibus-m17n
|
||||
```
|
||||
|
||||
The Ibus-m17n package provides a lot of Indian and other countries languages including amharic, arabic, armenian, assamese, athapascan languages, belarusian, bengali, burmese, central khmer, chamic languages, chinese, cree, croatian, czech, danish, divehi, dhivehi, maldivian, esperanto, french, georgian, ancient and modern greek, gujarati, hebrew, hindi, inuktitut, japanese, kannada, kashmiri, kazakh, korean, lao, malayalam, marathi, nepali, ojibwa, oriya, panjabi, punjabi, persian, pushto, pashto, russian, sanskrit, serbian, sichuan yi, nuosu, siksika, sindhi, sinhala, sinhalese, slovak, swedish, tai languages, tamil, telugu, thai, tibetan, uighur, uyghur, urdu, uzbek, vietnamese, as well as yiddish.
|
||||
|
||||
##### Add input languages
|
||||
|
||||
We can add languages in System **Settings** section. Click the drop down arrow on the top right corner of your Ubuntu desktop and choose Settings icon in the bottom left corner.
|
||||
|
||||
![][2]
|
||||
|
||||
Launch System’s settings from top panel
|
||||
|
||||
From the Settings section, click on **Region & Language** option in the left pane. Then click the **+** (plus) sign button on the right side under **Input Sources** tab.
|
||||
|
||||
![][3]
|
||||
|
||||
Region & language section in Settings section
|
||||
|
||||
In the next window, click on the **three vertical dots** button.
|
||||
|
||||
![][4]
|
||||
|
||||
Add input source in Ubuntu
|
||||
|
||||
Search and choose the input language you’d like to add from the list.
|
||||
|
||||
![][5]
|
||||
|
||||
Add input language
|
||||
|
||||
For the purpose of this guide, I am going to add **Tamil** language. After choosing the language, click **Add** button.
|
||||
|
||||
![][6]
|
||||
|
||||
Add Input Source
|
||||
|
||||
Now you will see the selected input source has been added. You will see it in Region & Language section under Input Sources tab.
|
||||
|
||||
![][7]
|
||||
|
||||
Input sources section in Ubuntu
|
||||
|
||||
Click the “Manage Installed Languages” button under Input Sources tab.
|
||||
|
||||
![][8]
|
||||
|
||||
Manage Installed Languages In Ubuntu
|
||||
|
||||
Next you will be asked whether you want to install translation packs for the chosen language. You can install them if you want. Or, simply choose “Remind Me Later” button. You will be notified when you open this next time.
|
||||
|
||||
![][9]
|
||||
|
||||
The language support is not installed completely
|
||||
|
||||
Once the translation packs are installed, Click **Install / Remove Languages** button. Also make sure IBus is selected in Keyboard input method system.
|
||||
|
||||
![][10]
|
||||
|
||||
Install / Remove Languages In Ubuntu
|
||||
|
||||
Choose your desired language from the list and click Apply button.
|
||||
|
||||
![][11]
|
||||
|
||||
Choose input language
|
||||
|
||||
That’s it. That’s we have successfully setup multilingual input method on Ubuntu 18.04 desktop. Similarly, add as many as input languages you want.
|
||||
|
||||
After adding all language sources, log out and log in back.
|
||||
|
||||
##### Type In Indian languages and/or your preferred languages
|
||||
|
||||
Once you have added all languages, you will see them from the drop download on the top bar of your Ubuntu desktop.
|
||||
|
||||
![][12]
|
||||
|
||||
Choose input language from top bar in Ubuntu desktop
|
||||
|
||||
Alternatively, you can use **SUPER+SPACE** keys from the Keyboard to switch between input languages.
|
||||
|
||||
![][13]
|
||||
|
||||
Choose input language using Super+Space keys in Ubuntu
|
||||
|
||||
Open any GUI text editors/apps and start typing!
|
||||
|
||||
![][14]
|
||||
|
||||
Type in Indian languages in Ubuntu
|
||||
|
||||
##### Add IBus to startup applications
|
||||
|
||||
We need let IBus to start automatically on every reboot, so you need not to start it manually whenever you want to type in your preferred language.
|
||||
|
||||
To do so, simply type “startup applications” in the dash and click on Startup Applications option.
|
||||
|
||||
![][15]
|
||||
|
||||
Launch startup applications in Ubuntu
|
||||
|
||||
In the next window, click Add, type “Ibus” in the name field and “ibus-daemon” in the Command field and then click Add button.
|
||||
|
||||
![][16]
|
||||
|
||||
Add Ibus to startup applications on Ubuntu
|
||||
|
||||
From now IBus will automatically start on system startup.
|
||||
|
||||
* * *
|
||||
|
||||
**Suggested read:**
|
||||
|
||||
* [**How To Use Google Translate From Commandline In Linux**][17]
|
||||
* [**How To Type Indian Rupee Sign (₹) In Linux**][18]
|
||||
* [**How To Setup Japanese Language Environment In Arch Linux**][19]
|
||||
|
||||
|
||||
|
||||
* * *
|
||||
|
||||
So, it is your turn now. What application/tool you’re using to type in local Indian languages? Let us know them in the comment section below.
|
||||
|
||||
**Reference:**
|
||||
|
||||
* [**IBus – Ubuntu Community Wiki**][20]
|
||||
|
||||
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
via: https://www.ostechnix.com/how-to-setup-multilingual-input-method-on-ubuntu/
|
||||
|
||||
作者:[sk][a]
|
||||
选题:[lujun9972][b]
|
||||
译者:[译者ID](https://github.com/译者ID)
|
||||
校对:[校对者ID](https://github.com/校对者ID)
|
||||
|
||||
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
|
||||
|
||||
[a]: https://www.ostechnix.com/author/sk/
|
||||
[b]: https://github.com/lujun9972
|
||||
[2]: https://www.ostechnix.com/wp-content/uploads/2019/07/Ubuntu-system-settings.png
|
||||
[3]: https://www.ostechnix.com/wp-content/uploads/2019/08/Region-language-in-Settings-ubuntu.png
|
||||
[4]: https://www.ostechnix.com/wp-content/uploads/2019/08/Add-input-source-in-Ubuntu.png
|
||||
[5]: https://www.ostechnix.com/wp-content/uploads/2019/08/Add-input-language.png
|
||||
[6]: https://www.ostechnix.com/wp-content/uploads/2019/08/Add-Input-Source-Ubuntu.png
|
||||
[7]: https://www.ostechnix.com/wp-content/uploads/2019/08/Input-sources-Ubuntu.png
|
||||
[8]: https://www.ostechnix.com/wp-content/uploads/2019/08/Manage-Installed-Languages.png
|
||||
[9]: https://www.ostechnix.com/wp-content/uploads/2019/08/The-language-support-is-not-installed-completely.png
|
||||
[10]: https://www.ostechnix.com/wp-content/uploads/2019/08/Install-Remove-languages.png
|
||||
[11]: https://www.ostechnix.com/wp-content/uploads/2019/08/Choose-language.png
|
||||
[12]: https://www.ostechnix.com/wp-content/uploads/2019/08/Choose-input-language-from-top-bar-in-Ubuntu.png
|
||||
[13]: https://www.ostechnix.com/wp-content/uploads/2019/08/Choose-input-language-using-SuperSpace-keys.png
|
||||
[14]: https://www.ostechnix.com/wp-content/uploads/2019/08/Setup-Multilingual-Input-Method-On-Ubuntu.png
|
||||
[15]: https://www.ostechnix.com/wp-content/uploads/2019/08/Launch-startup-applications-in-ubuntu.png
|
||||
[16]: https://www.ostechnix.com/wp-content/uploads/2019/08/Add-Ibus-to-startup-applications-on-Ubuntu.png
|
||||
[17]: https://www.ostechnix.com/use-google-translate-commandline-linux/
|
||||
[18]: https://www.ostechnix.com/type-indian-rupee-sign-%e2%82%b9-linux/
|
||||
[19]: https://www.ostechnix.com/setup-japanese-language-environment-arch-linux/
|
||||
[20]: https://help.ubuntu.com/community/ibus
|
@ -0,0 +1,143 @@
|
||||
[#]: collector: (lujun9972)
|
||||
[#]: translator: ( )
|
||||
[#]: reviewer: ( )
|
||||
[#]: publisher: ( )
|
||||
[#]: url: ( )
|
||||
[#]: subject: (How To Type Indian Rupee Sign (₹) In Linux)
|
||||
[#]: via: (https://www.ostechnix.com/type-indian-rupee-sign-%e2%82%b9-linux/)
|
||||
[#]: author: (sk https://www.ostechnix.com/author/sk/)
|
||||
|
||||
How To Type Indian Rupee Sign (₹) In Linux
|
||||
======
|
||||
|
||||
This brief guide explains how to type Indian Rupee sign in Unix-like operating systems. The other day, I wanted to type **“Indian Rupee Sign (₹)”**. My keyboard has rupee symbol on it, but I didn’t know how to type it. After a few google searches, I found a way to do this. If you ever wondered how to type rupee symbol in Linux, follow the steps given below.
|
||||
|
||||
### Type Indian Rupee Sign In Linux
|
||||
|
||||
The default keyboard layout in most GNU/Linux and other operating systems is **English (US)**. To type Indian rupee symbol, you need to change the Keyboard layout to **English (India, with rupee)**. I have given the steps to do this in three Desktop environments – **GNOME** , **MATE** and **KDE Plasma**. However, the steps are same for other DEs and other operating systems as well. Just find where the Keyboard layout settings is and change the layout to English (India, with rupee sign).
|
||||
|
||||
##### In GNOME Desktop Environment:
|
||||
|
||||
I tested this on Ubuntu 18.04 LTS desktop. This may work on other Linux distros with GNOME DE.
|
||||
|
||||
Click the drop down arrow on the top right corner of your Ubuntu desktop and choose **Settings** icon in the bottom left corner.
|
||||
|
||||
![][2]
|
||||
|
||||
Launch System’s settings from top panel
|
||||
|
||||
From the Settings section, click on **Region & Language** option in the left pane. Then click the **+** (plus) sign button on the right side under **Input Sources** tab.
|
||||
|
||||
![][3]
|
||||
|
||||
Region & language section in Settings section
|
||||
|
||||
In the next window, click on the **three vertical dots** button and choose the input language you’d like to add from the list.
|
||||
|
||||
![][4]
|
||||
|
||||
Add input source in Ubuntu
|
||||
|
||||
Scroll down a bit and search for **English (India)**. Click on it and then select **English (India, with rupee)** from list and finally click Add button.
|
||||
|
||||
![][5]
|
||||
|
||||
Choose “English (India, with rupee)” option
|
||||
|
||||
You will see it under Input Sources tab. If you want to make it as default, just choose it and click “UP” arrow button.
|
||||
|
||||
Close the Settings window and Log off and Log in back once.
|
||||
|
||||
Now choose the “English (India, with rupee)” from the language drop down box on the top bar of your Ubuntu desktop.
|
||||
|
||||
![][6]
|
||||
|
||||
Choose “English (India, with rupee)” option
|
||||
|
||||
Alternatively, you can use **SUPER+SPACE** keys from the Keyboard to choose it.
|
||||
|
||||
![][7]
|
||||
|
||||
Choose “English (India, with rupee)” option using super+space keys
|
||||
|
||||
Now, you can be able to type Indian rupee symbol by pressing **“Right ALT+4”**.
|
||||
|
||||
If your keyboard has the **AltGr key** on it, then press **AltGr+4** to type Indian rupee symbol.
|
||||
|
||||
Alternatively, you can use the key combination **“CTRL+SHIFT+u+20b9”** to type rupee symbol (Just hold CTRL+SHIFT keys and type **u20b9** letters and leave the keys). This will work everywhere.
|
||||
|
||||
##### In MATE Desktop Environment:
|
||||
|
||||
If you use MATE DE, go to **System - > Preferences -> Hardware -> Keyboard** from the Menu. Then, click on **Layouts** tab and click **Add** button to add a Indian keyboard layout.
|
||||
|
||||
![][8]
|
||||
|
||||
Add Keyboard layout in Keyboard preferences
|
||||
|
||||
Choose **India** from Country drop-down box and **Indian English (India, with rupee)** from Variants drop-down box. Click Add to add the chosen layout.
|
||||
|
||||
![][9]
|
||||
|
||||
Choose Indian English (India, with rupee) option
|
||||
|
||||
The Indian layout will be added to the Keyboard layout section. Choose it and click “Move up” to make it as default. Then, click “Options” button to choose the Keyboard layout options.
|
||||
|
||||
![][10]
|
||||
|
||||
From the Keyboard layout options windows, click on “Key to choose the 3rd level” and choose a key of your choice to apply for rupee symbol. I have chosen **“Any Alt”** key (So, I can use either left or right ALT keys).
|
||||
|
||||
![][11]
|
||||
|
||||
Close the keyboard preferences window.
|
||||
|
||||
Now, you can be able to type Indian rupee symbol by pressing **“ALT+4”**. Alternatively, you can use the key combination **“CTRL+SHIFT+u+20b9”** to type rupee symbol (Just hold CTRL+SHIFT keys and type **u20b9** letters and leave the keys). This will work everywhere.
|
||||
|
||||
Please note that this will work, only if your keyboard has **₹** symbol on **4**. If your keyboard doesn’t has this symbol or very old, it won’t work.
|
||||
|
||||
##### On KDE Plasma desktop environment:
|
||||
|
||||
If you use KDE Plasma, go to **Application Launcher - > System Settings -> Hardware -> Input Devices -> Keyboard -> Layouts**.
|
||||
|
||||
Check the box “Configure Layouts” and click “Add”.
|
||||
|
||||
![][12]
|
||||
|
||||
Choose “Indian” from Layout drop-down box and “English (India, rupee sign”) from Variant drop-down box.
|
||||
|
||||
![][13]
|
||||
|
||||
The chosen layout will be added to Layouts section. Choose it and click “Move up” to make it as default keyboard layout.
|
||||
|
||||
Then, click **Advanced** and click **“Key to choose the 3rd level”** and choose a key of your choice to apply for rupee symbol. I have chosen **“Any Alt”** key. Finally, click **“Apply”**.
|
||||
|
||||
![][14]
|
||||
|
||||
Now, you can be able to type Indian rupee symbol by pressing **“ALT+4”**. This procedure is same for all other DEs. All you have to do is find where keyboard layout is and change the layout to **English (India, rupee sign)**.
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
via: https://www.ostechnix.com/type-indian-rupee-sign-%e2%82%b9-linux/
|
||||
|
||||
作者:[sk][a]
|
||||
选题:[lujun9972][b]
|
||||
译者:[译者ID](https://github.com/译者ID)
|
||||
校对:[校对者ID](https://github.com/校对者ID)
|
||||
|
||||
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
|
||||
|
||||
[a]: https://www.ostechnix.com/author/sk/
|
||||
[b]: https://github.com/lujun9972
|
||||
[1]: data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7
|
||||
[2]: https://www.ostechnix.com/wp-content/uploads/2019/07/Ubuntu-system-settings.png
|
||||
[3]: https://www.ostechnix.com/wp-content/uploads/2019/08/Region-language-in-Settings-ubuntu.png
|
||||
[4]: https://www.ostechnix.com/wp-content/uploads/2019/08/Add-input-source-in-Ubuntu.png
|
||||
[5]: https://www.ostechnix.com/wp-content/uploads/2017/08/English-India-with-rupee-option.png
|
||||
[6]: https://www.ostechnix.com/wp-content/uploads/2017/08/Choose-English-India-with-rupee-option-from-language-bar.png
|
||||
[7]: https://www.ostechnix.com/wp-content/uploads/2017/08/Choose-English-India-with-rupee-option-using-superspace-keys.png
|
||||
[8]: https://www.ostechnix.com/wp-content/uploads/2017/08/Keyboard-Preferences_001.png
|
||||
[9]: https://www.ostechnix.com/wp-content/uploads/2017/08/Choose-a-Layout_002.png
|
||||
[10]: https://www.ostechnix.com/wp-content/uploads/2017/08/Keyboard-Preferences_003-1.png
|
||||
[11]: https://www.ostechnix.com/wp-content/uploads/2017/08/Keyboard-Layout-Options_004.png
|
||||
[12]: https://www.ostechnix.com/wp-content/uploads/2017/08/Keyboard-%E2%80%94-System-Settings_001.png
|
||||
[13]: https://www.ostechnix.com/wp-content/uploads/2017/08/Add-Layout-%E2%80%94-System-Settings_002.png
|
||||
[14]: https://www.ostechnix.com/wp-content/uploads/2017/08/Keyboard-layout-settings.png
|
@ -0,0 +1,227 @@
|
||||
[#]: collector: (lujun9972)
|
||||
[#]: translator: ( )
|
||||
[#]: reviewer: ( )
|
||||
[#]: publisher: ( )
|
||||
[#]: url: ( )
|
||||
[#]: subject: (SSLH – Share A Same Port For HTTPS And SSH)
|
||||
[#]: via: (https://www.ostechnix.com/sslh-share-port-https-ssh/)
|
||||
[#]: author: (sk https://www.ostechnix.com/author/sk/)
|
||||
|
||||
SSLH – Share A Same Port For HTTPS And SSH
|
||||
======
|
||||
|
||||
![SSLH - Share A Same Port For HTTPS And SSH][1]
|
||||
|
||||
Some Internet service providers and corporate companies might have blocked most of the ports, and allowed only a few specific ports such as port 80 and 443 to tighten their security. In such cases, we have no choice, but use a same port for multiple programs, say the HTTPS Port **443** , which is rarely blocked. Here is where **SSLH** , a SSL/SSH multiplexer, comes in help. It will listen for incoming connections on a port 443. To put this more simply, SSLH allows us to run several programs/services on port 443 on a Linux system. So, you can use both SSL and SSH using a same port at the same time. If you ever been in a situation where most ports are blocked by the firewalls, you can use SSLH to access your remote server. This brief tutorial describes how to share a same port for https, ssh using SSLH in Unix-like operating systems.
|
||||
|
||||
### SSLH – Share A Same Port For HTTPS, SSH, And OpenVPN
|
||||
|
||||
##### Install SSLH
|
||||
|
||||
SSLH is packaged for most Linux distributions, so you can install it using the default package managers.
|
||||
|
||||
On **Debian** , **Ubuntu** , and derivatives, run:
|
||||
|
||||
```
|
||||
$ sudo apt-get install sslh
|
||||
```
|
||||
|
||||
While installing SSLH, you will prompted whether you want to run sslh as a service from inetd, or as a standalone server. Each choice has its own benefits. With only a few connection per day, it is probably better to run sslh from inetd in order to save resources. On the other hand, with many connections, sslh should run as a standalone server to avoid spawning a new process for each incoming connection.
|
||||
|
||||
![][2]
|
||||
|
||||
Install sslh
|
||||
|
||||
On **Arch Linux** and derivatives like Antergos, Manjaro Linux, install it using Pacman as shown below.
|
||||
|
||||
```
|
||||
$ sudo pacman -S sslh
|
||||
```
|
||||
|
||||
On **RHEL** , **CentOS** , you need to add **EPEL** repository and then install SSLH as shown below.
|
||||
|
||||
```
|
||||
$ sudo yum install epel-release
|
||||
|
||||
$ sudo yum install sslh
|
||||
```
|
||||
|
||||
On **Fedora** :
|
||||
|
||||
```
|
||||
$ sudo dnf install sslh
|
||||
```
|
||||
|
||||
If it is not available on default repositories, you can manually compile and install SSLH as described [**here**][3].
|
||||
|
||||
##### Configure Apache or Nginx webservers
|
||||
|
||||
As you already know, Apache and Nginx webservers will listen on all network interfaces (i.e **0.0.0.0:443** ) by default. We need to change this setting to tell the webserver to listen on the localhost interface only (i.e **127.0.0.1:443 **or **localhost:443** ).
|
||||
|
||||
To do so, edit the webserver (nginx or apache) configuration file and find the following line:
|
||||
|
||||
```
|
||||
listen 443 ssl;
|
||||
```
|
||||
|
||||
And, change it to:
|
||||
|
||||
```
|
||||
listen 127.0.0.1:443 ssl;
|
||||
```
|
||||
|
||||
If you’re using Virutalhosts in Apache, make sure you have changed that it too.
|
||||
|
||||
```
|
||||
VirtualHost 127.0.0.1:443
|
||||
```
|
||||
|
||||
Save and close the config files. Do not restart the services. We haven’t finished yet.
|
||||
|
||||
##### Configure SSLH
|
||||
|
||||
Once you have made the webservers to listen on local interface only, edit SSLH config file:
|
||||
|
||||
```
|
||||
$ sudo vi /etc/default/sslh
|
||||
```
|
||||
|
||||
Find the following line:
|
||||
|
||||
```
|
||||
Run=no
|
||||
```
|
||||
|
||||
And, change it to:
|
||||
|
||||
```
|
||||
Run=yes
|
||||
```
|
||||
|
||||
Then, scroll a little bit down and modify the following line to allow SSLH to listen on port 443 on all available interfaces (Eg. 0.0.0.0:443).
|
||||
|
||||
```
|
||||
DAEMON_OPTS="--user sslh --listen 0.0.0.0:443 --ssh 127.0.0.1:22 --ssl 127.0.0.1:443 --pidfile /var/run/sslh/sslh.pid"
|
||||
```
|
||||
|
||||
Where,
|
||||
|
||||
* –user sslh : Requires to run under this specified username.
|
||||
* –listen 0.0.0.0:443 : SSLH is listening on port 443 on all available interfaces.
|
||||
* –sshs 127.0.0.1:22 : Route SSH traffic to port 22 on the localhost.
|
||||
* –ssl 127.0.0.1:443 : Route HTTPS/SSL traffic to port 443 on the localhost.
|
||||
|
||||
|
||||
|
||||
Save and close the file.
|
||||
|
||||
Finally, enable and start sslh service to update the changes.
|
||||
|
||||
```
|
||||
$ sudo systemctl enable sslh
|
||||
|
||||
$ sudo systemctl start sslh
|
||||
```
|
||||
|
||||
##### Testing
|
||||
|
||||
Check if the SSLH daemon is listening to 443.
|
||||
|
||||
```
|
||||
$ ps -ef | grep sslh
|
||||
sslh 2746 1 0 15:51 ? 00:00:00 /usr/sbin/sslh --foreground --user sslh --listen 0.0.0.0 443 --ssh 127.0.0.1 22 --ssl 127.0.0.1 443 --pidfile /var/run/sslh/sslh.pid
|
||||
sslh 2747 2746 0 15:51 ? 00:00:00 /usr/sbin/sslh --foreground --user sslh --listen 0.0.0.0 443 --ssh 127.0.0.1 22 --ssl 127.0.0.1 443 --pidfile /var/run/sslh/sslh.pid
|
||||
sk 2754 1432 0 15:51 pts/0 00:00:00 grep --color=auto sslh
|
||||
```
|
||||
|
||||
Now, you can access your remote server via SSH using port 443:
|
||||
|
||||
```
|
||||
$ ssh -p 443 [email protected]
|
||||
```
|
||||
|
||||
**Sample output:**
|
||||
|
||||
```
|
||||
[email protected]'s password:
|
||||
Welcome to Ubuntu 18.04.2 LTS (GNU/Linux 4.15.0-55-generic x86_64)
|
||||
|
||||
* Documentation: https://help.ubuntu.com
|
||||
* Management: https://landscape.canonical.com
|
||||
* Support: https://ubuntu.com/advantage
|
||||
|
||||
System information as of Wed Aug 14 13:11:04 IST 2019
|
||||
|
||||
System load: 0.23 Processes: 101
|
||||
Usage of /: 53.5% of 19.56GB Users logged in: 0
|
||||
Memory usage: 9% IP address for enp0s3: 192.168.225.50
|
||||
Swap usage: 0% IP address for enp0s8: 192.168.225.51
|
||||
|
||||
* Keen to learn Istio? It's included in the single-package MicroK8s.
|
||||
|
||||
https://snapcraft.io/microk8s
|
||||
|
||||
61 packages can be updated.
|
||||
22 updates are security updates.
|
||||
|
||||
|
||||
Last login: Wed Aug 14 13:10:33 2019 from 127.0.0.1
|
||||
```
|
||||
|
||||
![][4]
|
||||
|
||||
Access remote systems via SSH using port 443
|
||||
|
||||
See? I can now be able to access the remote server via SSH even if the default SSH port 22 is blocked. As you see in the above example, I have used the https port 443 for SSH connection. Also, we can use the same port 443 for openVPN connections too.
|
||||
|
||||
* * *
|
||||
|
||||
**Suggested read:**
|
||||
|
||||
* [**How To SSH Into A Particular Directory On Linux**][5]
|
||||
* [**How To Create SSH Alias In Linux**][6]
|
||||
* [**How To Configure SSH Key-based Authentication In Linux**][7]
|
||||
* [**How To Stop SSH Session From Disconnecting In Linux**][8]
|
||||
* [**Allow Or Deny SSH Access To A Particular User Or Group In Linux**][9]
|
||||
* [**4 Ways To Keep A Command Running After You Log Out Of The SSH Session**][10]
|
||||
* [**ScanSSH – Fast SSH Server And Open Proxy Scanner**][11]
|
||||
|
||||
|
||||
|
||||
* * *
|
||||
|
||||
I tested SSLH on my Ubuntu 18.04 LTS server and it worked just fine as described above. I tested SSLH in a protected local area network, so I am not aware of the security issues. If you’re using it in production, let us know the advantages and disadvantages of using SSLH in the comment section below.
|
||||
|
||||
For more details, check the official GitHub page given below.
|
||||
|
||||
**Resource:**
|
||||
|
||||
* [**SSLH GitHub Repository**][12]
|
||||
|
||||
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
via: https://www.ostechnix.com/sslh-share-port-https-ssh/
|
||||
|
||||
作者:[sk][a]
|
||||
选题:[lujun9972][b]
|
||||
译者:[译者ID](https://github.com/译者ID)
|
||||
校对:[校对者ID](https://github.com/校对者ID)
|
||||
|
||||
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
|
||||
|
||||
[a]: https://www.ostechnix.com/author/sk/
|
||||
[b]: https://github.com/lujun9972
|
||||
[1]: https://www.ostechnix.com/wp-content/uploads/2017/08/SSLH-Share-A-Same-Port-For-HTTPS-And-SSH-1-720x340.jpg
|
||||
[2]: https://www.ostechnix.com/wp-content/uploads/2017/08/install-sslh.png
|
||||
[3]: https://github.com/yrutschle/sslh/blob/master/doc/INSTALL.md
|
||||
[4]: https://www.ostechnix.com/wp-content/uploads/2017/08/Access-remote-systems-via-SSH-using-port-443.png
|
||||
[5]: https://www.ostechnix.com/how-to-ssh-into-a-particular-directory-on-linux/
|
||||
[6]: https://www.ostechnix.com/how-to-create-ssh-alias-in-linux/
|
||||
[7]: https://www.ostechnix.com/configure-ssh-key-based-authentication-linux/
|
||||
[8]: https://www.ostechnix.com/how-to-stop-ssh-session-from-disconnecting-in-linux/
|
||||
[9]: https://www.ostechnix.com/allow-deny-ssh-access-particular-user-group-linux/
|
||||
[10]: https://www.ostechnix.com/4-ways-keep-command-running-log-ssh-session/
|
||||
[11]: https://www.ostechnix.com/scanssh-fast-ssh-server-open-proxy-scanner/
|
||||
[12]: https://github.com/yrutschle/sslh
|
Loading…
Reference in New Issue
Block a user