Skip to main content

Posts

Showing posts from 2020

System Time Problem on Windows and Linux Dual Bootable Systems

 When two operating systems are installed into the same disk, a problem may be encountered about time. Boot a Linux Distro and see what time is it and boot into Windows and see is the time correct or not? Windows is set to use local time, Linux Distro's are set to use UTC. So this problem can be solved in Windows to set UTC.  Go to command prompt, open it with administrative privilages and use the command below: reg add "HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\TimeZoneInformation" /v RealTimeIsUniversal /d 1 /t REG_DWORD /f

How to Make a Write-Protected USB Flash Drive

To make write protection on a USB drive, you need some editing using diskpart program in terminal.  First, press windows logo and write command or find command line shortcut and click on it. When the window opens, write diskpart in it (picture 1 below). If you did not start command line with administrator privileges, diskpart asks you when it starts. Then write "list disk" command (picture 2 below). See and determine the USB drive that you want to make write-protection. In my case, it is "Disk 1"... Use "select disk 1" command (picture 3 below). Use "attributes disk set readonly" command (picture 4 below).  That's all... When you want to copy or delete some files in it, do steps from 1 to 5 and then use "attributes disk clear readonly" command...

Android 11 for LG G2

Beloved old mobile phone, LG G2 got a new milestone to update its operating system with the support of a few XDA developers.  The first step of updated firmware, the initial release has been uploaded to one of developer's personel cloud storage. It can be found here .  Well done and thanks to the developers. 

Windows 10 Does Not Allow to Use LG Sound Bar as Output Speaker

Problem & Solution  If you have an LG soundbar, you may encountered a problem when you tried to make a connection. I have an LG NB2540 soundbar. Windows 10 can easly connect to this device but when I want to listen to music, I can not hear any sound from this soundbar. I still hear it from my laptop's internal speaker. Last year, I have found a solution on Microsoft's Community. I have used my soundbar happily until now. Recently, I needed to do a fresh install of windows. So I needed to solve this problem again. The solution is very easy.  Remove LG soundbar from bluetooth devices section. Press start menu on Windows. Write "command prompt". Click "Run as administrator". When it opens, write this command without qoutes and press enter: "reg add HKLM\SYSTEM\ControlSet001\Control\Bluetooth\Audio\AVRCP\CT /v DisableAbsoluteVolume /t REG_DWORD /d 1 /f" Add again on bluetooth devices section. Well done! Source of this solution:  https://answers.mic...

How to Add or Resize Your Swap Partition on Linux

I have a laptop with an SSD and an HDD. SSD includes Windows. HDD include Ubuntu 20.04. For some reasons, I need to resize, merge, move the partitions of HDD...  This will be a "How to" post...  First, unmount or disable the swap partition. Because it is impossible editing while it is active.  Install GParted.  After selecting the right disk, do the changes like merging, resizing and moving.  When it was done, use "blkid" command to determine the new UUID of new swap.  Open /etc/fstab/ with gedit. (sudo gedit /etc/fstab/) Find the line which included "sw" There is a UUID which is old partition's one. Change this UUID with the new one learned with blkid command. Then save and close the gedit windows. Now it is time to control that new swap is active or not. Use this command: "free -m". If you see memory line and swap line on the screen, you did everything right. If not, there is a mistake in somewhere above.

Solution of Error Message: "Ignoring file 'XXXXXXXXXXXX.save' in directory '/etc/apt/sources.list.d/' as it has an invalid filename extension"

While using Ubuntu 20.04, I've encountered the warning in the subject line of this post after using update command in terminal. I think it is about some compatibility problem with the sources added after Ubuntu setup.  I tried to get rid of that message deleting all the ".save" files in /etc/apt/sources.list.d/ directory. But no way... After first use of update command, they have been created again.  After a little research, I found a solution as a workaround. Writing the below command hides the warning message forever:  sudo sh -c "echo 'Dir::Ignore-Files-Silently:: \"(.save|.distupgrade)$\";' > /etc/apt/apt.conf.d/99ignoresave"

Installation of Hardware Virtualization Support on Ubuntu

While installing Android Studio on Ubuntu, it warned me to install hardware virtualization support for better performance. My CPU supports this technology. I think it should come while installation of operating system. But anyway, there are lots of information to install it: https://help.ubuntu.com/community/KVM/Installation Just follow the directions on the page.

Error: Sub-process /usr/bin/dpkg returned an error code (1)

When a process locks the debconf config.dat file, you may get this error.  The solution of this error is identifying the process and killing it. You can find the guilty process wtih this command:  sudo fuser -v /var/cache/debconf/config.dat You will get an PID on the screen. And you can use this PID in the following command: sudo kill THAT_PID_NUMBER_GOT_ABOVE_COMMAND or you can just use the following code to kill the process without seeing PID number: sudo fuser -v -k /var/cache/debconf/config.dat All these info has been taken from askubuntu community .

What to do If Your Keyboard's AltGR Key is Broken

AltGr Key A little water has been spilled on my laptop's keyboard. And just one key has been broken now. AltGr key... My keyboard is Turkish Q setup. AltGr key is important for following characters: ₺ # $ € @ { } [ ] \ | ~  If you use Windows, you can use CTRL+ALT key combination. It behaves same as AltGr key. Or you can use alt codes. For instance while pressing ALT key, press 64 on numpad. With this combination, you can write @ character on the screen. These two solutions are very efficient for Windows operating system.  On Ubuntu, you can't use alt codes while pressing ALT key. Because ALT key has some other shortcut duties for productivity. You can't use CTRL+ALT combination too.  So, thinked about today. How can i write those special characters. Of course researched about it. And found a solution.  There ise an application in Ubuntu Software store. "GnomeTweaks" First install it. Then run it.  Go to keyboard and mouse section. Go to additional options. Find...

How to Stop File System Check on Every Boot in Ubuntu

While determining the default OS to boot, I have edited too much files. May be I did a wrong thing. Now I realised that on every boot, Ubuntu splash screen says there is a file system check. This bothered me. After a little research, found a solution.  You need to edit fstab file in /etc/fstab . Open the file using this command:  sudo nano /etc/fstab Pay attention the uncommented lines. At the end of each line there is a parameter "0" or "1" or "2". 0: force the system not to do  a file system check 1: force the system to do a file system check at every boot 2: force the system to do a just one file system check at the next first boot I've change the parameters to "0" and reboot.  Voila! There is no "file system check" warning at boot.

Modifying UEFI & GRUB Settings to Determine Default OS

This is for the people who wants to change the UEFI and/or GRUB2 configuration. Why? To change boot order or to set default operating system to boot.  I have a laptop which is installed an SSD and a SATA HDD. SSD for Windows 10 (without SSD, working with Windows is like going somewhere on a turtle) and sata HDD for Ubuntu 20.04.  I don't know why, Windows take the charge of booting process. It boots without asking me. But I want my pc to ask me which OS should be booted, and if I do not give it an input, it should boot Windows. I can be able to choose Ubuntu whenever I want. Because of my wife, my system should be set up as default operating system is Windows. If you do not an input, computer should boot up into Windows. Because she has some difficulties with linux systems.  How to Solve This? First it is needed to force the pc to boot into Ubuntu. And Ubuntu should ask which OS should be booted (because Windows never asks this or I do not know how to make it as...

C# ?: (Question Mark Dot) Operator

I liked this operator. It is called "ternary" operator too. I can use it instead of basic "if" statements. Syntax of this: condition ? consequent : alternative And the code sample:   1 2 3 4 5 6 7 8 9 10 using System ; class Operators { static void Main () {start: //a label to start again Console.Write( "Do you want to continue? (y, n): " ); string answer = Console.ReadLine(); Console.WriteLine(answer == "y" ? "Congrats!" : "See you later!" ); goto start; } }

A Sample of C# Variables and Data Input From User

This is a"how to" to get two different datas from user and define them to two different variables: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 using System; namespace Variables { class Program { static void Main(string[] args) { starthere: Console . WriteLine( "Please enter first number:" ); int first = Convert . ToInt32(Console . ReadLine()); Console . WriteLine( "Please enter second number which is greater then the first:" ); int second = Convert . ToInt32(Console . ReadLine()); if (first < second) { Console . WriteLine( " \n Let's count them from smaller to greater: \n " ); for ( int i = first; i <= second; i ++ ) { Console . WriteLine(i); } } else ...

My First C# Program

C# is a popular programming language produced and mainteined by Microsoft. This page is included basics of C# programming language and my learning steps with some code snippets. On following lines, there is my first program's codes. It runs in "console" application. using System ; namespace Basics { class Program { static void Main ( string [ ] args ) { Console . Title = ( "Started to Learn!" ) ; // Set a title for CMD window. basla : // a flag to return here back. Console . WriteLine ( "What is your name? " ) ; // Printing to the screen   string ad = Console . ReadLine ( ) ; // set a variable named "ad" and waiting for user input. Console . WriteLine ( " \n How old are you" ) ; // Text which was printed on the screen. "\n" flag is for jum...

A Solution to Play Some Streaming Videos Which Do Not Play on Ubuntu

While using Ubuntu, the last version, you may encounter that everything works perfect on YouTube. But if you encountered some streaming videos can not be played on some sites in Ubuntu, now you have a solution. Ubuntu needs a video library to be installed  to play all the videos on all ths web sites. Installing  "libavcodec-extra"  package in package manager or using following command in terminal solves this issue:  < sudo apt install libavcodec-extra >

Transforming an old PC to a MediaCenter With LibreElec

I had an old PC with ultra thin form factor. Foxxconn NetBox NT-330-i which specifications are Intel Atom330 CPU at 1.6 GHz, 2GB DDR2 RAM at 800MHz, onboard Nvidia ION GPU. This hardware can not run "nowadays" operating systems smoothly. My netbox' operating system was Windows XP which is not supported by Microsoft and other software companies. So I needed to find a solution.       Got an HDMI cable, connected it to my TV. Got a wireless keyboard and connected to my netbox. Then I downloaded x86_64 version of  LiberElec . I downloaded a tool to make a bootable USB of this image file from  here . Then connected a USB stick and ran this tool. It did everthing. Next step was booting this little computer from USB. I followed the instructions and installed LibreELEC to my netbox.   LiberElec is a Linux based operating system that includes just  KODI project . LiberElec's motto is "Just enough OS for KODI". KODI is ...

Android 10 for LG G2

LG's popular mobile phone which produced in 2013 is still alive. This magical touch comes from a few XDA developers  and LineageOS crew. Thanks to all of these heros. With the version 17.1 of LineageOS, you can use your "old" phone with the latest Android version. All you need to do is go to the wiki page of this device in LineageOS's web site  and follow the instructions. Here are two screenshots from the device:  

Covid-19 Pandemi ve Sokağa Çıkma Yasağı

Son günlerde yaşadıklarımız, ekonomi ve ticaretin, sağlıktan sonraki en önemli şey olduğunu hatırlattı bana. Diğer ülkeler inanılmaz büyüklükte destek paketleri açıklarken, ülkemiz ekonomi yönetiminin vatandaştan destek istemesi ve esasında toplum ve bireylere doğrudan etkisinin sınırlı olabileceği bir paket açıklamaları, ekonominin ve ekonomi yönetiminin, kaynakların doğru kullanımının ve şeffaflığın önemini ortaya koyuyor. Öte yandan ticaretin devamı için de şirketlerin her şeyi yapacağını görüyoruz. TV reklamlarında dikkatimi çekenlerden bazıları da bunu destekliyor. Bir temizlik ürünleri firmasının ev içi hijyen için satışa sunduğu ürünlerinin reklamını izledim. Güncel farkındalık nedeniyle herkesin satınalma kararında ön planda olan ürünlerden... Hemen ardından bir e-ticaret firmasının kişisel bakım ürünlerinin reklamını; ki bunlar arasında saç tıraş makinesi vardı. Günlerdir yasal olarak sokağa çıkamayan 20 yaş altı ve 60 yaş üstü insanlar ile kendi kararıyla kendisini izole ...

Excel - SUMPRODUCT Formula / How to Count Cells According to Multiple Criteria

While using Excel, sometimes we need to count some cells which have special qualitatives.  Excel can count all the cells which included an important number for us, a text which special for us... An Example:  If you want to know how many "yellow" cells are "glass 4mm", just write this code:  =SUMPRODUCT((C3:C16="Yellow")*(B3:B16="Glass 4mm")) If you want to know how many "black" glasses have 20 or less quantity, this code is for you:  =SUMPRODUCT((C3:C16="Black")*(D3:D16>=20)) If you want to know how many products is less than 20 and cheaper or equal to 100$, this is the code:  =SUMPRODUCT((E4:E16<=100)*(D4:D16<=20)) These samples can be reproduced. You just need to write suitable code for your scenario.

Excel - VLOOKUP Formula / Pulling Data From Another Database or File

In Excel, if you have two different .xlsx file and just 1 common information in these files, you can use VLOOKUP command to match&pull datas and combine them...  For example you can use if you have same columns included citizenship number, customer number, telephone number etc. Formula Example:   Include into C2 cell this formula without quotas: "=VLOOKUP(B2:B6;[A.xlsx]Sheet1!$A$2:$E$6;4;0)" Include into D2 cell this formula without quotas: "=VLOOKUP(B2:B6;[A.xlsx]Sheet1!$A$2:$E$6;5;0)" A tip from the Microsoft's website: In its simplest form, the VLOOKUP function says: =VLOOKUP(What you want to look up, where you want to look for it, the column number in the range containing the value to return, return an Approximate or Exact match – indicated as 1/TRUE, or 0/FALSE). Note: VLOOKUP searches left to right. If you want to search top to bottom, you can use HLOOKUP command. Here are the sample files: A.xlsx B.xlsx