發表文章

在windows 10 pro版中VirtualBox 無法使用64-bit作業系統,但intel VT-x虛擬機已從bios開啟,解決方法(但bios已經開啟)。

圖片
在windows 10 最近的更新後,虛擬機軟體(Oracle VirtualBox)重灌後無法使用intel VT-x。 去下載intel 的工具 haxm_check.exe 執行後 VT support -- yes NX support -- yes 但在VirtualBox中仍舊無法新增64-bit作業系統,也無法使用從其他電腦匯入的64-bit作業系統。 解決方法為: 1. bios 要開啟(本教學以筆記型電腦 Thinkpad P50為例): Virtualization -> Intel Virtualization technology。 Enabled Virtualization -> Intel VT-d。 Enabled 2. windows 10 請確定Hyper-V是關閉的。 Hyper-V關閉方法:控制台->程式集->程式和功能->開啟或關閉windows功能。 確定都沒有選擇Hyper-V的功能。如下圖: 打開 Windows Defender資訊安全中心。(從工作bar中點選盾牌圖案) 打開後,按下裝置安全性(click “Device Security”) 打開後,按下核心隔離(click “Core Isolation”) 打開後,關閉記憶體完整性(disabled “Memory Integrity”) 做完後重新開機(reboot)。 這樣Oracle VirtualBox應該就可以使用64-bit作業系統。 thats it. reference:  https://superuser.com/questions/1153470/vt-x-is-not-available-but-is-enabled-in-bios

在ubuntu發送信件e-mail的5個方法

圖片
We all know the importance of emails these days for information transfer. There are many free emails service providers which we used for use like Gmail, Yahoo, RediffMail etc, which provides a web interface for sending and receiving emails. But this is not enough, sometimes we also required to send emails from system command line. This tutorial will provide you multiple ways to send emails from the Linux command line. This is useful for sending email through our shell scripts, cronjobs etc. There are various ways to send emails from the command line but here I am sharing few options used by most users. You can use anyone option given below to send email from Linux command line. 1. Using ‘sendmail’ Command Sendmail is a most popular SMTP server used in most of Linux/Unix distribution. Sendmail allows sending email from command line. Use below instructions to send email using ‘ sendmail ‘ command. Created a file with email content: cat /tmp/email.txt Subject: Terminal Email...

How To Send Email from Gmail or SMTP via Linux Command

In our earlier tutorial we had discussed about  SSMTP  for sending email through SMTP server via command line. This tutorial makes this process much easier using the sendemail command line utility. SendEmail is a Lightweight command line SMTP email client for sending emails through the SMTP server. In this article, we have described how to install sendemail package and a few examples for sending email through remote SMTP server like Gmail. Install SendEmail Package SendEmail SMTP client is available under default Ubuntu repositories, Use following commands to install it. sudo apt-get update sudo apt-get install sendemail Send Email through SMTP Example 1:- In this example email body text is passed as argument (-o message-file=/tmp/mailbody.txt) in command. sendemail -l email.log \ -f "sender@domain.com" \ -u "Email Subject 1" \ -t "receiver@domain.com" \ -s "smtp.gmail.com:587" \ -o tls=yes \ -xu ...

UBUNTU No module named "apt_pkg" 錯誤修復。

圖片
$ sudo apt-get remove --purge python-apt $ sudo apt-get install python-apt -f $ sudo find / -name "apt_pkg.cpython-35m-x86_64-linux-gnu.so" $ cd /usr/lib/python3/dist-packages/ $ sudo cp apt_pkg.cpython-35m-x86_64-linux-gnu.so apt_pkg.cpython-36m-x86_64-linux-gnu.so 背景 : 系統 : ubuntu16.04 python 版本 : 默認版本原來是 python2.7,  先裝了 python3.5=python3.5.3 , 後又裝了 python3.6=python3.6.1 將默認版本改為 python3.6 後就出現 No module named "apt_pkg" 的問題了 : 本來 Ctrl+Alt+T 是打開終端的快速鍵 , 突然用不了 , 去到鍵盤裡面的快速鍵設置看到命令還是 `gnome-terminal` 打開一個終端 , 運行 `gnome-terminal` 就出現如下錯誤了 : ... Error in sys.excepthook: Traceback (most recent call last):   File "/usr/lib/python3/dist-packages/apport_python_hook.py", line 63, in apport_excepthook     from apport.fileutils import likely_packaged, get_recent_crashes   File "/usr/lib/python3/dist-packages/apport/__init__.py", line 5, in <module>     from apport.report import Report   File "...

How to Run Chkdsk in Ubuntu

How to Run Chkdsk in Ubuntu Chkdsk is the Windows command for checking hard drives for errors and repairing them, if possible. If your company uses the Ubuntu Linux operating system rather than Windows, the chkdsk command will not work. The equivalent command for the Linux operating system is "fsck." You can only run this command on disks and filesystems that are not mounted (available for use). If you want to check a root filesystem (the filesystem that contains the base operating system commands), you should boot to a live Ubuntu CD. 1. Right-click on the desktop and choose the "Open in Terminal" option from the menu that appears. A terminal window opens. 2.   Type the following command to unmount the drive you want to check: sudo umount /dev/sdb Replace "/dev/sdb" with the device name for the drive you want to check. 3. Type the following command to check the drive: sudo fsck /dev/sdb The command may take some time to c...

How to Install FreeCAD 0.18 in Ubuntu 18.04

圖片
FreeCAD, free and open-source 3D parametric modeler, released version 0.18 recently with  Python 3  and  Qt 5  support. Here’s how to install it in Ubuntu 16.04, Ubuntu 18.04, and Ubuntu 19.04. FreeCAD 0.18  release highlights: Extended TechDraw tools New sketcher tools, more stable and robust PartDesign Enhanced and extended Arch and BIM tools Redesigned Start center New Navigation Cube Specify a custom background image for FreeCAD’s main window Install or Upgrade FreeCAD in Ubuntu: The official  FreeCAD PPA  has built the latest release packages for Ubuntu 16.04, Ubuntu 18.04, Ubuntu 19.04, and their derivatives. 1.  Open terminal either via  Ctrl+Alt+T  keyboard shortcut, or by searching for ‘terminal’ from app menu. When it opens, run command to add the PPA: sudo add-apt-repository ppa:freecad-maintainers/freecad-stable Type user password (no asterisk feedback) when it prompts and hit Enter to continue. 2. ...

How to setting gcc and g++ symbolic link for any version of install on Ubuntu 18.04

How to setting gcc and g++ symbolic link for any version of install on Ubuntu 18.04 1. delete /usr/bin/ gcc and g++ $ cd / usr / bin $ sudo rm gcc g ++ 2. do symbolic link for gcc-7 and g++-7 $ sudo ln - s gcc - 7 gcc $ sudo ln - s g ++ - 7 g ++ that's it.