This will create a duplicate file called greetings.txt.old so you can compare.
sed -i '.old' 's/Hello/Goodbye/' greetings.txt
mv greetings.txt.old greetings.txt
y
The empty string says to override the current file.
sed -i '' 's/Hello/Goodbye/' greetings.txt